Package jade.core

Examples of jade.core.CaseInsensitiveString


   * @param value The new value of the attribute. If <code>value</code>
   * is null the current mapping with <code>name</code> (if any) is
   * removed.
   */
  protected void set(String name, AbsObject value) {
    CaseInsensitiveString ciName = new CaseInsensitiveString(name);
    if (value == null) {
      orderedKeys.remove(name);
      elements.remove(ciName);
    }
    else {
View Full Code Here


   * @param name The name of the attribute.
   * @return value The value of the attribute.
   * @see AbsObject#getAbsObject(String)
   */
  public AbsObject getAbsObject(String name) {
    return (AbsObject) elements.get(new CaseInsensitiveString(name));
  }
View Full Code Here

   */
  public void registerOntology(Ontology o, String name) {
    if (o == null) {
      throw new IllegalArgumentException("Null ontology registered");
    }
    ontologies.put(new CaseInsensitiveString(name), o);
  }
View Full Code Here

   * @return the <code>Codec</code> associated to
   * <code>name</code> or <code>null</code> if no Codec was registered
   * with the given name.
   */
  public Codec lookupLanguage(String name) {
    return (name==null?null:(Codec) languages.get(new CaseInsensitiveString(name)));
  }
View Full Code Here

   * @return the <code>Ontology</code> associated to
   * <code>name</code> or <code>null</code> if no Ontology was registered
   * with the given name.
   */
  public Ontology lookupOntology(String name) {
    return (name==null?null:(Ontology) ontologies.get(new CaseInsensitiveString(name)));
  }
View Full Code Here

   * @param slotSchema The schema defining the type of the slot.
   * @param optionality The optionality, i.e., <code>OPTIONAL</code>
   * or <code>MANDATORY</code>
   */
  protected void add(String name, ObjectSchema slotSchema, int optionality) {
    CaseInsensitiveString ciName = new CaseInsensitiveString(name);
    if (slots == null) {
      slots = new Hashtable();
      slotNames = new Vector();
    }
    if (slots.put(ciName, new SlotDescriptor(name, slotSchema, optionality)) == null) {
View Full Code Here

   @throws OntologyException if slotName does not identify
   a valid slot in this schema
   */
  protected void addFacet(String slotName, Facet f) throws OntologyException {
    if (containsSlot(slotName)) {
      CaseInsensitiveString ciName = new CaseInsensitiveString(slotName);
      if (facets == null) {
        facets = new Hashtable();
      }
      Vector v = (Vector) facets.get(ciName);
      if (v == null) {
View Full Code Here

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

   * @param name The <code>String</code> to test.
   * @return <code>true</code> if <code>name</code> is the name of a
   * slot defined in this <code>Schema</code>.
   */
  public boolean containsSlot(String name) {
    SlotDescriptor slot = getSlot(new CaseInsensitiveString(name));
    return (slot != null);
  }
View Full Code Here

   * @param name The <code>String</code> to test.
   * @return <code>true</code> if <code>name</code> is the name of a
   * slot actually defined in this <code>Schema</code> (excluding super-schemas).
   */
  public boolean isOwnSlot(String name) {
    SlotDescriptor slot = getOwnSlot(new CaseInsensitiveString(name));
    return (slot != null);
  }
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.