code: @SafeVarargs
      public static Document toDocument(final Object... a) {
          if (N.isNullOrEmpty(a)) {
              return new Document();
          }
  
          return a.length == 1 ? toDocument(a[0]) : toDocument((Object) a);
      }
docs: Create a new document with specified parameter(s). It could an array of property name and value, or a map, or an entity.
  
  @param a
  @return