Package jade.core

Examples of jade.core.CaseInsensitiveString


   * @return <code>true</code> if the slot is mandatory.
   * @throws OntologyException If no slot with this name is present
   * in this schema.
   */
  public boolean isMandatory(String name) throws OntologyException {
    SlotDescriptor slot = getSlot(new CaseInsensitiveString(name));
    if (slot == null) {
      throw new OntologyException("No slot named: " + name);
    }
    return slot.optionality == MANDATORY;
  }
View Full Code Here


  protected void validateSlots(AbsObject abs, Ontology onto) throws OntologyException {
    // Validate all the attributes in the abstract descriptor
    String[] slotNames = getNames();
    for (int i = 0; i < slotNames.length; ++i) {
      AbsObject slotValue = abs.getAbsObject(slotNames[i]);
      CaseInsensitiveString ciName = new CaseInsensitiveString(slotNames[i]);
      validate(ciName, slotValue, onto);
    }
  }
View Full Code Here

   * up to the schema actually declaring the given slot.
   * @return the facets defined upon a slot or null if the specified slot is not found.
   */
  Vector getAllFacets(String slotName) { // Package-scoped for testing purposes only
    Vector allFacets = new Vector();
    CaseInsensitiveString caseInsensitiveSlotName = new CaseInsensitiveString(slotName);
    if (facets != null) {
      Vector v = (Vector)facets.get(caseInsensitiveSlotName);
      if (v != null) {
        // We don't use Vector.addAll() for MIDP compatibility
        addAll(allFacets, v);
View Full Code Here

TOP

Related Classes of jade.core.CaseInsensitiveString

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.