Class Feature.Create

  • Enclosing class:
    Feature

    public static class Feature.Create
    extends java.lang.Object
    • Method Detail

      • binaryFeature

        public static Feature binaryFeature​(java.lang.String name,
                                            byte[] value)
      • stringFeature

        public static Feature stringFeature​(java.lang.String name,
                                            java.lang.String value)
      • byteFeature

        public static Feature byteFeature​(java.lang.String name,
                                          java.lang.Byte value)
      • shortFeature

        public static Feature shortFeature​(java.lang.String name,
                                           java.lang.Short value)
      • intFeature

        public static Feature intFeature​(java.lang.String name,
                                         java.lang.Integer value)
      • longFeature

        public static Feature longFeature​(java.lang.String name,
                                          java.lang.Long value)
      • floatFeature

        public static Feature floatFeature​(java.lang.String name,
                                           java.lang.Float value)
      • doubleFeature

        public static Feature doubleFeature​(java.lang.String name,
                                            java.lang.Double value)
      • bigIntegerFeature

        public static Feature bigIntegerFeature​(java.lang.String name,
                                                java.math.BigInteger value)
      • bigDecimalFeature

        public static Feature bigDecimalFeature​(java.lang.String name,
                                                java.math.BigDecimal value)
      • uuidFeature

        public static Feature uuidFeature​(java.lang.String name,
                                          java.util.UUID value)
      • dateFeature

        public static Feature dateFeature​(java.lang.String name,
                                          java.util.Date value)
      • from

        public static Feature from​(java.lang.String s)
        Create a feature from a string representation of the feature. The feature has to have the following format
             name:TYPE=value
         
        the :TYPE part may be missing in case the feature type is STRING. The value has to be the string representation of the value that is different for each type.
        Parameters:
        s - the feature as string
        Returns:
        the new object created from the string
      • from

        public static Feature from​(byte[] serialized)
        Create the feature from the binary serialized format. The format is defined in the documentation of the method Feature.serialized().
        Parameters:
        serialized - the serialized format.
        Returns:
        a new feature object