Class FieldDescription

    • Constructor Detail

      • FieldDescription

        public FieldDescription​(String name,
                                FieldType type)
      • FieldDescription

        public FieldDescription​(String name,
                                String type)
      • FieldDescription

        public FieldDescription​(String name,
                                FieldType type,
                                boolean mandatory)
      • FieldDescription

        public FieldDescription​(String name,
                                String type,
                                String aliases)
      • FieldDescription

        public FieldDescription​(String name,
                                String typeString,
                                String aliases,
                                boolean mandatory,
                                boolean overridable)
        Creates a field description
        Parameters:
        name - the name of the field
        typeString - the type of the field represented as a string - see FieldType
        aliases - a space-separated list of alias names of this field name. Aliases are not following dotted (meaning they are global, not that they cannot contain dots) and are case insensitive. Null is permissible if there are no aliases
        mandatory - whether it is mandatory to provide a value for this field. default: false
        overridable - whether this can be overridden when first set in a profile. Default: true
      • FieldDescription

        public FieldDescription​(String name,
                                FieldType type,
                                boolean mandatory,
                                boolean overridable)
      • FieldDescription

        public FieldDescription​(String name,
                                FieldType type,
                                String aliases,
                                boolean mandatory,
                                boolean overridable)
      • FieldDescription

        public FieldDescription​(com.yahoo.processing.request.CompoundName name,
                                FieldType type,
                                String aliases,
                                boolean mandatory,
                                boolean overridable)
        Creates a field description from a list where the aliases are represented as a comma-separated string
      • FieldDescription

        public FieldDescription​(com.yahoo.processing.request.CompoundName name,
                                FieldType type,
                                List<String> aliases,
                                boolean mandatory,
                                boolean overridable)
        Creates a field description
        Parameters:
        name - the name of the field
        type - the type of the field represented as a string - see FieldType
        aliases - a list of aliases, never null. Aliases are not following dotted (meaning they are global, not that they cannot contain dots) and are case insensitive.
        mandatory - whether it is mandatory to provide a value for this field. default: false
        overridable - whether this can be overridden when first set in a profile. Default: true
    • Method Detail

      • getName

        public String getName()
        Returns the full name of this as a string
      • getCompoundName

        public com.yahoo.processing.request.CompoundName getCompoundName()
        Returns the full name of this as a compound name
      • getAliases

        public List<String> getAliases()
        Returns a unmodifiable list of the aliases of this. An empty list (never null) if there are none.
      • isMandatory

        public boolean isMandatory()
        Returns whether this field must be provided in the query profile or the search definition. Default: false
      • isOverridable

        public boolean isOverridable()
        Returns false if overrides to values for this field from the outside should be ignored. Default: true
      • withName

        public FieldDescription withName​(com.yahoo.processing.request.CompoundName name)
        Returns a copy of this with the name set to the argument name
      • withType

        public FieldDescription withType​(FieldType type)
        Returns a copy of this with the type set to the argument type