Class Compound

All Implemented Interfaces:
Describable, Identifiable

@Indexed public class Compound extends AbstractDescribable
  • Constructor Details

    • Compound

      public Compound()
  • Method Details

    • getId

      @DocumentId public Long getId()
      Description copied from interface: Identifiable
      Obtain the identifier of the object.
      Specified by:
      getId in interface Identifiable
      Overrides:
      getId in class AbstractIdentifiable
    • getName

      @Field public String getName()
      Description copied from interface: Describable
      Obtain the name of the object.

      It may be human-readable.

      It is case-insensitive and usually unique within a certain context (e.g. in a collection).

      It is non-null by default, but implementation may override this with a Nullable annotation. If null, it should not be treated as equal to other Describable objects (i.e. there can be multiple null-named describable within a given set).

      Specified by:
      getName in interface Describable
      Overrides:
      getName in class AbstractDescribable
    • getRegistryNumber

      @Field(analyze=NO) public String getRegistryNumber()
      Returns:
      CAS registry number (see http://www.cas.org/)
    • setRegistryNumber

      public void setRegistryNumber(String registryNumber)
    • equals

      public boolean equals(Object object)
      Description copied from class: AbstractDescribable
      Important note: The name should be compared in a case-insensitive manner. You can use DescribableUtils.equalsByName(Describable, Describable) to get the correct behavior.

      Important note: Two objects with the same class and non-null ID must be considered equal. If one or both IDs are nulls, the rest of the state can be used to determine equality.

      Specified by:
      equals in class AbstractDescribable