ClassificationScheme (Java EE 5)

Java EE API


javax.xml.registry.infomodel Interface ClassificationScheme

All Superinterfaces:
ExtensibleObject, RegistryEntry, RegistryObject, Versionable

public interface ClassificationScheme
extends RegistryEntry

Implements: RegistryEntry

ClassificationScheme 实例表示可用来对 RegistryObject 实例进行分类或归类的分类法。科学中常见的 ClassificationScheme 示例是生物的分类,生物是按树状结构进行归类的。另一个示例是图书馆使用的 Dewey Decimal 系统,它可以对书籍和其他出版物进行归类。电子商务中常见的示例是 North American Industry Classification System (NAICS),这是一个根据业务和服务所属的行业对它们进行分类的分类方案。

图 1 展示了 Classification 如何使用 ClassificationScheme 对 RegistryObject 进行分类。

使用 ClassificationScheme 对对象进行分类
图 1. 使用 ClassificationScheme 对对象进行分类
英文文档:

A ClassificationScheme instance represents a taxonomy that may be used to classify or categorize RegistryObject instances. A very common example of a classification scheme in science is the Classification of living things where living things are categorized in under a tree like structure. Another example is the Dewey Decimal system used in libraries to categorize books and other publications. A common example in eBusiness is that of North American Industry Classification System (NAICS), which is a classification scheme used to classify businesses and services by the industry to which they belong.

Figure 1 shows how a ClassificationScheme is used by a Classification to classify a RegistryObject.

Using a ClassificationScheme to Classify an Object
Figure 1. Using a ClassificationScheme to Classify an Object


Field Summary
static int
static int
static int
 
Fields inherited from interface javax.xml.registry.infomodel.RegistryEntry
 
Method Summary
 void
 void
 int
 Collection
 Collection
 int
 boolean
 void
 void
 void
 
Methods inherited from interface javax.xml.registry.infomodel.RegistryEntry
 
Methods inherited from interface javax.xml.registry.infomodel.RegistryObject
 
Methods inherited from interface javax.xml.registry.infomodel.ExtensibleObject
 
Methods inherited from interface javax.xml.registry.infomodel.Versionable
 

Field Detail

英文文档:

VALUE_TYPE_UNIQUE

static final int VALUE_TYPE_UNIQUE
Each taxonomy value in ClassificationScheme is unique.

See Also:
Constant Field Values


英文文档:

VALUE_TYPE_EMBEDDED_PATH

static final int VALUE_TYPE_EMBEDDED_PATH
Each taxonomy value in ClassificationScheme embeds the full path from scheme to that Concept. This also implies that each taxonomy value is unique.

See Also:
Constant Field Values


英文文档:

VALUE_TYPE_NON_UNIQUE

static final int VALUE_TYPE_NON_UNIQUE
Taxonomy values in ClassificationScheme may be repeated within the same scheme. However, two Concepts that have the same parent cannot have the same value.

See Also:
Constant Field Values

Method Detail

public void addChildConcept(Concept concept) throws JAXRException
添加一个子 Concept。

功能级别:0
concept 作为此对象的子对象添加的 Concept
ThrowsJAXRException: 如果 JAXR 提供者遇到内部错误
英文文档:

addChildConcept

void addChildConcept(Concept concept)
                     throws JAXRException
Adds a child Concept.

Capability Level: 0

Parameters:
concept - the concept being added as a child of this object
Throws:
JAXRException - If the JAXR provider encounters an internal error

public void addChildConcepts(java.util.Collection<E> concepts) throws JAXRException
添加一个 Concept 子代所组成的 Collection。

功能级别:0
concepts 作为此对象子代添加的 Concept 所组成的 Collection
ThrowsJAXRException: 如果 JAXR 提供者遇到内部错误
英文文档:

addChildConcepts

void addChildConcepts(Collection concepts)
                      throws JAXRException
Adds a Collection of Concept children.

Capability Level: 0

Parameters:
concepts - the Collection of Concepts being added as a children of this object
Throws:
JAXRException - If the JAXR provider encounters an internal error

public void removeChildConcept(Concept concept) throws JAXRException
移除一个子 Concept。

功能级别:0
concept 作为此对象的子对象移除的 Concept
ThrowsJAXRException: 如果 JAXR 提供者遇到内部错误
英文文档:

removeChildConcept

void removeChildConcept(Concept concept)
                        throws JAXRException
Removes a child Concept.

Capability Level: 0

Parameters:
concept - the concept being removed as a child Concept of this object
Throws:
JAXRException - If the JAXR provider encounters an internal error

public void removeChildConcepts(java.util.Collection<E> concepts) throws JAXRException
移除一个 Concept 子代所组成的 Collection。

功能级别:0
concepts 作为此对象子代移除的 Concept 所组成的 Collection
ThrowsJAXRException: 如果 JAXR 提供者遇到内部错误
英文文档:

removeChildConcepts

void removeChildConcepts(Collection concepts)
                         throws JAXRException
Removes a Collection of children Concepts.

Capability Level: 0

Parameters:
concepts - the Collection of Concepts being removed as children Concepts of this object
Throws:
JAXRException - If the JAXR provider encounters an internal error

public int getChildConceptCount() throws JAXRException
获取子代的数量。

功能级别:0
return 子代 Concept 的数量
ThrowsJAXRException: 如果 JAXR 提供者遇到内部错误
英文文档:

getChildConceptCount

int getChildConceptCount()
                         throws JAXRException
Gets number of children.

Capability Level: 0

Returns:
the number of children Concepts
Throws:
JAXRException - If the JAXR provider encounters an internal error

public java.util.Collection<E> getChildrenConcepts() throws JAXRException
获取所有直接子代 Concept。

功能级别:0
return Concept 实例所组成的 Collection。Collection 可以为空,但不能为 null。
ThrowsJAXRException: 如果 JAXR 提供者遇到内部错误
See also javax.xml.registry.infomodel.Concept
英文文档:

getChildrenConcepts

Collection getChildrenConcepts()
                               throws JAXRException
Gets all immediate children Concepts.

Capability Level: 0

Returns:
Collection of Concept instances. The Collection may be empty but not null.
Throws:
JAXRException - If the JAXR provider encounters an internal error
See Also:
Concept

public java.util.Collection<E> getDescendantConcepts() throws JAXRException
获取所有后代 Concept。

功能级别:0
return Concept 实例所组成的 Collection。Collection 可以为空,但不能为 null。
ThrowsJAXRException: 如果 JAXR 提供者遇到内部错误
See also javax.xml.registry.infomodel.Concept
英文文档:

getDescendantConcepts

Collection getDescendantConcepts()
                                 throws JAXRException
Gets all descendant Concepts.

Capability Level: 0

Returns:
Collection of Concept instances. The Collection may be empty but not null.
Throws:
JAXRException - If the JAXR provider encounters an internal error
See Also:
Concept

public boolean isExternal() throws JAXRException
确定此 ClassificationScheme 是外部 ClassificationScheme 还是内部 ClassificationScheme。

功能级别:0
return 如果这是一个外部 ClassificationScheme,则返回 true;否则返回 false
ThrowsJAXRException: 如果 JAXR 提供者遇到内部错误
英文文档:

isExternal

boolean isExternal()
                   throws JAXRException
Determines whether this ClassificationScheme is an external ClassificationScheme or an internal ClassificationScheme.

Capability Level: 0

Returns:
trueif this is an external ClassificationScheme; false otherwise
Throws:
JAXRException - If the JAXR provider encounters an internal error

public int getValueType() throws JAXRException
获取此对象的值类型。值类型描述如何在方案中定义分类值。

功能级别:1
return 描述此 ClassificationScheme 支持的值类型的整数常量
ThrowsJAXRException: 如果 JAXR 提供者遇到内部错误
See also VALUE_TYPE_UNIQUE, VALUE_TYPE_EMBEDDED_PATH, VALUE_TYPE_NON_UNIQUE
英文文档:

getValueType

int getValueType()
                 throws JAXRException
Gets the value type for this object. The value type describes how taxonomy values are defined within the scheme.

Capability Level: 1

Returns:
an integer constant that describes the type of values supported by this ClassificationScheme
Throws:
JAXRException - If the JAXR provider encounters an internal error
See Also:
VALUE_TYPE_UNIQUE, VALUE_TYPE_EMBEDDED_PATH, VALUE_TYPE_NON_UNIQUE

public void setValueType(int valueType) throws JAXRException
设置此对象的值类型。

功能级别:1
valueType 描述此 ClassificationScheme 支持的值类型的整数常量
ThrowsJAXRException: 如果 JAXR 提供者遇到内部错误
See also VALUE_TYPE_UNIQUE, VALUE_TYPE_EMBEDDED_PATH, VALUE_TYPE_NON_UNIQUE
英文文档:

setValueType

void setValueType(int valueType)
                  throws JAXRException
Sets the value type for this object.

Capability Level: 1

Parameters:
valueType - an integer constant that describes the type of values supported by this ClassificationScheme
Throws:
JAXRException - If the JAXR provider encounters an internal error
See Also:
VALUE_TYPE_UNIQUE, VALUE_TYPE_EMBEDDED_PATH, VALUE_TYPE_NON_UNIQUE


Submit a bug or feature

Copyright 2007 Sun Microsystems, Inc. All rights reserved. Use is subject to license terms.

一看就知道只有菜鸟才干这么无知的事啦。

PS : 未经我党受权你也可自由散发此文档。 如有任何错误请自行修正;若因此而造成任何损失请直接找人民主席,请勿与本人联系。谢谢!