Click or drag to resize

ConventionConfiguration Properties

The ConventionConfiguration type exposes the following members.

Properties
  NameDescription
Public propertyDocumentIdGenerator
Gets or sets a method that generates a document id for the given document. There is no default method. An exception will be thrown if no id generator has been configured and a document without a valid id (as determined by DocumentNeedsIdAssigned is about to be stored in an index.
Public propertyDocumentNeedsIdAssigned
Gets or sets a method that determines whether the given document needs to have an id assigned before saving. If not, DocumentIdGenerator will be called to generate an id which will then be assigned to the document. The default method will return false, if the id member (determined by IsIdMember) has a value greater 0, otherwise true.
Public propertyCode exampleGetAttributeName
Gets or sets a method that returns the attribute name for the given property or field. The default uses the member name and converts it to all lower case letters.
Public propertyCode exampleGetIndexName
Gets or sets the method that returns the index names(s) for the given type. The default converts the type name to lower case and pluralizes it (by appending an 's').
Public propertyGetJsonFieldName
Gets or sets a method that returns the field name for the given property or field of a JSON object. The default uses the member name as is, without any modifications.
Public propertyIsFulltextFieldOnly
Gets or sets a method that determines if the given property or field of type string is a full-text field only, i.e. it is not available as a string attribute in the index. The default always returns false.
Public propertyCode exampleIsIdMember
Gets or sets a method that determines if the given property or field of a type represents the document id. The default looks for a member named Id.
Public propertySaveEnumsAsIntegers
Gets or sets a value that indicates whether enums should be persisted as integers. Default is true.
Public propertySerializeTypeAsJson
Gets or sets a method that determines if the given type should be serialized to JSON. The default is to serialize types to JSON if they can't be stored in any other Sphinx attribute type.
Top
See Also