com.apelon.dts.client.concept
Class OntylogClassQuery

java.lang.Object
  extended by com.apelon.apelonserver.client.BasicQuery
      extended by com.apelon.dts.client.attribute.QualifierTypeQuery
          extended by com.apelon.dts.client.attribute.PropertyTypeQuery
              extended by com.apelon.dts.client.concept.BaseConceptQuery
                  extended by com.apelon.dts.client.concept.BaseOntylogConceptQuery
                      extended by com.apelon.dts.client.concept.OntylogClassQuery

public abstract class OntylogClassQuery
extends BaseOntylogConceptQuery

OntylogClassQueryServer supports queries on subconcept relationships within an Ontylog concept hierarchy. Ontylog concepts reside in a namespace provided by subscription from Apelon, or loaded from a TDE database.

Copyright: Copyright (c) 2003

Company: Apelon, Inc.

Since:
DTS 3.0.0
Version:
DTS 3.0.0
Author:
Apelon, Inc.

Field Summary
 
Fields inherited from class com.apelon.dts.client.concept.BaseConceptQuery
conceptListener
 
Fields inherited from class com.apelon.dts.client.attribute.QualifierTypeQuery
kbtypeListener
 
Fields inherited from class com.apelon.apelonserver.client.BasicQuery
ADMIN, queryHeader
 
Method Summary
static OntylogClassQuery createInstance(ServerConnection sc)
          Creates an instance of OntylogClassQuery.
static OntylogClassQuery createInstance(ServerConnection sc, boolean isValidating)
          Creates an instance of OntylogClassQueryServer.
 OntylogConcept[] getSubConcepts(OntylogConcept concept, ConceptAttributeSetDescriptor dtsAsd)
          Gets all the subconcepts of the concept argument with attributes filled in according to the ConceptAttributeSetDescriptor.
 boolean isSubConcept(OntylogConcept concept1, OntylogConcept concept2)
          Determines if concept1 is a subconcept of concept2.
 boolean[] isSubConcept(OntylogConcept concept1, OntylogConcept[] concepts)
          Determines if concept1 is a subconcept of an array of concepts.
 boolean isSubConceptByCode(String concept1, String concept2, int namespaceId)
          Determines if concept1 is a subconcept of concept2.
 boolean isSubConceptById(int conceptId1, int conceptId2, int namespaceId)
          Determines if concept1 is a subconcept of concept2.
 boolean[] isSubConceptByName(String concept1, String[] concepts, int namespaceId)
          Determines if concept1 is a subconcept of concepts.
 boolean isSubConceptByName(String concept1, String concept2, int namespaceId)
          Determines if concept1 is a subconcept of concept2 in the specified namespace.
 
Methods inherited from class com.apelon.dts.client.concept.BaseOntylogConceptQuery
addRoleType, assertIsNotNull, deleteRoleType, deleteRoleType, fetchParentReferences, fetchRightIdentityReferences, findRoleTypeByCode, findRoleTypeById, findRoleTypeByName, getAllKinds, getAllRoleTypes, getKinds, getResponse, getRoleTypes, isRoleTypeUsed, updateRoleType
 
Methods inherited from class com.apelon.dts.client.concept.BaseConceptQuery
addConceptListener, addProperty, addSynonym, deleteProperty, deleteSynonym, findConceptByCode, findConceptById, findConceptByName, findConceptsByCode, findConceptsById, findConceptsByName, fireConceptAction, getAllConceptPropertyTypes, getConceptListener, getConceptPropertyTypes, getNamespaceQuery, removeConceptListener, updateProperty, updateSynonym
 
Methods inherited from class com.apelon.dts.client.attribute.PropertyTypeQuery
addPropertyType, buildPropertyTypes, deletePropertyType, findPropertyTypeByCode, findPropertyTypeById, findPropertyTypeByName, isPropertyTypeUsed, updatePropertyType
 
Methods inherited from class com.apelon.dts.client.attribute.QualifierTypeQuery
addKBTypeListener, addQualifierType, deleteQualifierType, findQualifierTypeByCode, findQualifierTypeById, findQualifierTypeByName, fireKBTypeAction, getAllConceptAssociationQualifierTypes, getAllConceptPropertyQualifierTypes, getAllQualifierTypes, getAllTermAssociationQualifierTypes, getAllTermPropertyQualifierTypes, getConceptAssociationQualifierTypes, getConceptPropertyQualifierTypes, getKBTypeListener, getTermAssociationQualifierTypes, getTermPropertyQualifierTypes, removeKBTypeListener, updateQualifierType
 
Methods inherited from class com.apelon.apelonserver.client.BasicQuery
executeQuery, executeQueryNoParse, getServerConnection, initializeDtds, initializeDtds, ping, setVersion
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Method Detail

createInstance

public static OntylogClassQuery createInstance(ServerConnection sc)
                                        throws IllegalArgumentException
Creates an instance of OntylogClassQuery. Depending on the type of ServerConnection object passed in the argument, the server may be local(JDBC), socket, or another implementation.

Parameters:
sc - the type of server connection
Returns:
the created OntylogClassQueryServer
Throws:
IllegalArgumentException - if a null server connection is passed
See Also:
ServerConnectionJDBC, ServerConnectionSocket

createInstance

public static OntylogClassQuery createInstance(ServerConnection sc,
                                               boolean isValidating)
                                        throws IllegalArgumentException
Creates an instance of OntylogClassQueryServer. Depending on the type of ServerConnection object passed in the argument, the server may be local(JDBC), socket, or another implementation. The second argument is a boolean value for XML validation.

Parameters:
sc - the type of server connection
isValidating - a boolean value. It is true if XML needs to be validated, otherwise it is false.
Returns:
the created OntylogClassQueryServer
Throws:
IllegalArgumentException - if a null server connection is passed
See Also:
ServerConnectionJDBC, ServerConnectionSocket

isSubConcept

public boolean isSubConcept(OntylogConcept concept1,
                            OntylogConcept concept2)
                     throws DTSException
Determines if concept1 is a subconcept of concept2.

Parameters:
concept1 - an Ontylog concept
concept2 - an Ontylog concept
Returns:
true if concept1 is a subconcept of concept2, false if concept1 isn't a subconcept of concept2
Throws:
DTSException - if any error occurs in the method

isSubConcept

public boolean[] isSubConcept(OntylogConcept concept1,
                              OntylogConcept[] concepts)
                       throws DTSException
Determines if concept1 is a subconcept of an array of concepts.

Parameters:
concept1 - an Ontylog concept
concepts - an array of Ontylog concepts
Returns:
an array of booleans indicating if concept1 is a subconcept of the corresponding concept in the array of concepts
Throws:
DTSException - if any error occurs in the method

isSubConceptByName

public boolean isSubConceptByName(String concept1,
                                  String concept2,
                                  int namespaceId)
                           throws DTSException
Determines if concept1 is a subconcept of concept2 in the specified namespace. Concept1 and concept2 are names of Ontylog concepts.

Parameters:
concept1 - a concept name
concept2 - a concept name
namespaceId - namespace ID of the two Ontylog concepts
Returns:
true if concept1 is a subconcept of concept2, false if concept1 isn't a subconcept of concept2
Throws:
DTSException - if any error occurs in the method

isSubConceptById

public boolean isSubConceptById(int conceptId1,
                                int conceptId2,
                                int namespaceId)
                         throws DTSException
Determines if concept1 is a subconcept of concept2. Concept1 and concept2 are IDs of concepts.

Parameters:
conceptId1 - a concept ID
conceptId2 - a concept ID
namespaceId - namespace ID of the two Ontylog concepts
Returns:
true if concept1 is a subconcept of concept2, false if concept1 isn't a subconcept of concept2
Throws:
DTSException - if any error occurs in the method

isSubConceptByCode

public boolean isSubConceptByCode(String concept1,
                                  String concept2,
                                  int namespaceId)
                           throws DTSException
Determines if concept1 is a subconcept of concept2. Concept1 and concept2 are codes of concepts.

Parameters:
concept1 - a concept code
concept2 - a concept code
namespaceId - namespace ID of the two Ontylog concepts
Returns:
true if concept1 is a subconcept of concept2, false if concept1 isn't a subconcept of concept2
Throws:
DTSException - if any error occurs in the method

isSubConceptByName

public boolean[] isSubConceptByName(String concept1,
                                    String[] concepts,
                                    int namespaceId)
                             throws DTSException
Determines if concept1 is a subconcept of concepts. Concepts is an array of concept names. Concept1 is a concept name.

Parameters:
concept1 - a concept name
concepts - an array of concept names
namespaceId - namespace ID of the Ontylog concepts
Returns:
an array of booleans indicating if concept1 is a subconcept of the corresponding concept in the array of concepts
Throws:
DTSException - if any error occurs in the method

getSubConcepts

public OntylogConcept[] getSubConcepts(OntylogConcept concept,
                                       ConceptAttributeSetDescriptor dtsAsd)
                                throws DTSException
Gets all the subconcepts of the concept argument with attributes filled in according to the ConceptAttributeSetDescriptor.

Parameters:
concept - a concept
dtsAsd - a ConceptAttributeSetDescriptor
Returns:
an array of concepts which are subconcepts of a concept with attributes filled in according to the ConceptAttributeSetDescriptor.
Throws:
DTSException - if any error occurs in the method


Copyright © 2011. All Rights Reserved.