public final class InterfaceDescription extends Object
Constructor and Description |
---|
InterfaceDescription(String packageName,
String name)
Create a new interface description with the specified package name
and name.
|
InterfaceDescription(String license,
String packageName,
String name)
Create a new interface description with the specified package name
and name.
|
InterfaceDescription(String packageName,
String name,
String author,
String version,
String description)
Create a new interface description from the specified parameters.
|
InterfaceDescription(String packageName,
String lower,
String mixed,
String upper,
String author,
String version,
String description)
Create a new interface description from the specified parameters.
|
InterfaceDescription(String packageName,
String lower,
String mixed,
String upper,
String author,
String version,
String description,
Set<InterfaceDescription> specializes,
Set<Attribute> attributes,
Set<Association> associations)
Create a new interface description from the specified parameters.
|
Modifier and Type | Method and Description |
---|---|
boolean |
addAssociation(Association association)
Add the specified association to the set of associations
for this interface description.
|
boolean |
addAttribute(Attribute attribute)
Add the specified attribute to the set of attributes
for this interface description.
|
boolean |
addSpecializes(InterfaceDescription specializes)
Add the specified interface description to the set of interfaces this interface
description specializes.
|
boolean |
associate(Association association)
Add the specified association to the set of associations
for this interface description.
|
boolean |
associate(ClassDescription cd,
Cardinality cardinality)
Add a new association to the set of associations for this
interface description to the specified class with the
specified cardinality.
|
boolean |
associate(ClassDescription cd,
Cardinality cardinality,
boolean indexed,
boolean unique,
boolean ordered,
boolean sorted)
Add a new association to the set of associations for this
interface description to the specified class with the specified
parameters.
|
boolean |
associate(ClassDescription cd,
String roleName,
Cardinality cardinality)
Add a new association to the set of attributes for this
interface description to the specified class with the
specified role name and cardinality.
|
boolean |
associate(ClassDescription cd,
String roleName,
Cardinality cardinality,
boolean indexed,
boolean unique,
boolean ordered,
boolean sorted)
Add a new association to the set of associations for this
interface description to the specified class with the specified
parameters.
|
boolean |
associate(InterfaceDescription id,
Cardinality cardinality)
Add a new association to the set of associations for this
interface description to the specified interface with the
specified cardinality.
|
boolean |
associate(InterfaceDescription id,
Cardinality cardinality,
boolean indexed,
boolean unique,
boolean ordered,
boolean sorted)
Add a new association to the set of associations for this
interface description to the specified interface with the specified
parameters.
|
boolean |
associate(InterfaceDescription id,
String roleName,
Cardinality cardinality)
Add a new association to the set of attributes for this
interface description to the specified interface with the
specified role name and cardinality.
|
boolean |
associate(InterfaceDescription id,
String roleName,
Cardinality cardinality,
boolean indexed,
boolean unique,
boolean ordered,
boolean sorted)
Add a new association to the set of associations for this
interface description to the specified interface with the specified
parameters.
|
boolean |
attribute(Attribute attribute)
Add the specified attribute to the set of attributes
for this interface description.
|
boolean |
attribute(String name,
String roleName,
Cardinality cardinality)
Add a new attribute to the set of attributes for this
interface description with the specified name, role name,
and cardinality.
|
boolean |
attribute(String name,
String roleName,
Cardinality cardinality,
boolean indexed,
boolean unique,
boolean ordered,
boolean sorted)
Add a new attribute to the set of attributes for this
interface description with the specified parameters.
|
Set<Association> |
getAssociations()
Return an unmodifiable set of associations for this interface description.
|
Set<Attribute> |
getAttributes()
Return an unmodifiable set of attributes for this interface description.
|
String |
getAuthor()
Return the author for this interface description.
|
String |
getDescription()
Return the description for this interface description.
|
String |
getLicense()
Return the license for this interface description.
|
String |
getLower()
Return the lowercase name for this interface description.
|
String |
getMixed()
Return the mixed-case name for this interface description.
|
String |
getPackageName()
Return the package name for this interface description.
|
Set<InterfaceDescription> |
getSpecializes()
Return an unmodifiable set of interfaces this interface description specializes.
|
String |
getUpper()
Return the uppercase name for this interface description.
|
String |
getVersion()
Return the version for this interface description.
|
boolean |
specializes(InterfaceDescription specializes)
Add the specified interface description to the set of interfaces this interface
description specializes.
|
public InterfaceDescription(String packageName, String name)
packageName
- package name for this interface descriptionname
- name of this interface descriptionpublic InterfaceDescription(String license, String packageName, String name)
license
- license for this interface descriptionpackageName
- package name for this interface descriptionname
- name of this interface descriptionpublic InterfaceDescription(String packageName, String name, String author, String version, String description)
packageName
- package name for this interface descriptionname
- uppercase name for this interface descriptionauthor
- author for this interface descriptionversion
- version for this interface descriptiondescription
- description for this interface descriptionpublic InterfaceDescription(String packageName, String lower, String mixed, String upper, String author, String version, String description)
packageName
- package name for this interface descriptionlower
- lowercase name for this interface descriptionmixed
- mixed-case name for this interface descriptionupper
- uppercase name for this interface descriptionauthor
- author for this interface descriptionversion
- version for this interface descriptiondescription
- description for this interface descriptionpublic InterfaceDescription(String packageName, String lower, String mixed, String upper, String author, String version, String description, Set<InterfaceDescription> specializes, Set<Attribute> attributes, Set<Association> associations)
The interfaces this interface description specializes in specializes
are copied defensively
into this class.
The attributes in attributes
are copied defensively
into this class.
The associations in associations
are copied defensively
into this class.
packageName
- package name for this interface descriptionlower
- lowercase name for this interface descriptionmixed
- mixed-case name for this interface descriptionupper
- uppercase name for this interface descriptionauthor
- author for this interface descriptionversion
- version for this interface descriptiondescription
- description for this interface descriptionspecializes
- set of interfaces this interface description specializes, must not be nullattributes
- set of attributes, must not be nullassociations
- set of associations, must not be nullpublic String getLicense()
public String getPackageName()
public String getLower()
public String getMixed()
public String getUpper()
public String getAuthor()
public String getVersion()
public String getDescription()
public Set<InterfaceDescription> getSpecializes()
public boolean addSpecializes(InterfaceDescription specializes)
true
if the set of interfaces this
interface description specializes changed as a result of this call.specializes
- interface description to add, must not be nulltrue
if the set of interfaces this interface description specializes
changed as a result of this callpublic boolean specializes(InterfaceDescription specializes)
true
if the set of interfaces this
interface description specializes changed as a result of this call.specializes
- interface description to add, must not be nulltrue
if the set of interfaces this interface description specializes
changed as a result of this callpublic Set<Attribute> getAttributes()
public boolean addAttribute(Attribute attribute)
true
if the set
of attributes changed as a result of this call.attribute
- attribute to add, must not be nulltrue
if the set of attributes
changed as a result of this callpublic boolean attribute(Attribute attribute)
true
if the set
of attributes changed as a result of this call.attribute
- attribute to add, must not be nulltrue
if the set of attributes
changed as a result of this callpublic boolean attribute(String name, String roleName, Cardinality cardinality)
true
if
the set of attributes changed as a result of this call.name
- attribute nameroleName
- role namecardinality
- cardinality, must not be null and must be
one of Cardinality.ZeroToOne or Cardinality.StrictlyOnetrue
if the set of attributes
changed as a result of this callpublic boolean attribute(String name, String roleName, Cardinality cardinality, boolean indexed, boolean unique, boolean ordered, boolean sorted)
true
if the set of attributes changed as
a result of this call.name
- attribute nameroleName
- role namecardinality
- cardinality, must not be nullindexed
- true if the collection should be indexedunique
- true if the collection should not allow duplicate elementsordered
- true if the collection should iterate over elements in insertion-ordersorted
- true if the collection should iterate over elements in ascending element order,
sorted according to the natural ordering of its elements (see Comparable), or by a Comparator
provided at creation timetrue
if the set of attributes
changed as a result of this callpublic Set<Association> getAssociations()
public boolean addAssociation(Association association)
true
if the set
of associations changed as a result of this call.association
- association to add, must not be nulltrue
if the set of associations
changed as a result of this callpublic boolean associate(Association association)
true
if the set
of associations changed as a result of this call.association
- association to add, must not be nulltrue
if the set of associations
changed as a result of this callpublic boolean associate(ClassDescription cd, Cardinality cardinality)
true
if the set of associations changed as a result of
this call.cd
- class description, must not be nullcardinality
- cardinality, must not be null and must be
one of Cardinality.ZeroToOne or Cardinality.StrictlyOnetrue
if the set of associations
changed as a result of this callpublic boolean associate(ClassDescription cd, String roleName, Cardinality cardinality)
true
if the set of associations changed as a result of
this call.cd
- class description, must not be nullroleName
- role namecardinality
- cardinality, must not be null and must be
one of Cardinality.ZeroToOne or Cardinality.StrictlyOnetrue
if the set of associations
changed as a result of this callpublic boolean associate(ClassDescription cd, Cardinality cardinality, boolean indexed, boolean unique, boolean ordered, boolean sorted)
cd
- class description, must not be nullcardinality
- cardinality, must not be nullindexed
- true if the collection should be indexedunique
- true if the collection should not allow duplicate elementsordered
- true if the collection should iterate over elements in insertion-ordersorted
- true if the collection should iterate over elements in ascending element order,
sorted according to the natural ordering of its elements (see Comparable), or by a Comparator
provided at creation timetrue
if the set of associations
changed as a result of this callpublic boolean associate(ClassDescription cd, String roleName, Cardinality cardinality, boolean indexed, boolean unique, boolean ordered, boolean sorted)
cd
- class description, must not be nullroleName
- role namecardinality
- cardinality, must not be nullindexed
- true if the collection should be indexedunique
- true if the collection should not allow duplicate elementsordered
- true if the collection should iterate over elements in insertion-ordersorted
- true if the collection should iterate over elements in ascending element order,
sorted according to the natural ordering of its elements (see Comparable), or by a Comparator
provided at creation timetrue
if the set of associations
changed as a result of this callpublic boolean associate(InterfaceDescription id, Cardinality cardinality)
true
if the set of associations changed as a result of
this call.id
- interface description, must not be nullcardinality
- cardinality, must not be null and must be
one of Cardinality.ZeroToOne or Cardinality.StrictlyOnetrue
if the set of associations
changed as a result of this callpublic boolean associate(InterfaceDescription id, String roleName, Cardinality cardinality)
true
if the set of associations changed as a result of
this call.id
- interface description, must not be nullroleName
- role namecardinality
- cardinality, must not be null and must be
one of Cardinality.ZeroToOne or Cardinality.StrictlyOnetrue
if the set of associations
changed as a result of this callpublic boolean associate(InterfaceDescription id, Cardinality cardinality, boolean indexed, boolean unique, boolean ordered, boolean sorted)
id
- interface description, must not be nullcardinality
- cardinality, must not be nullindexed
- true if the collection should be indexedunique
- true if the collection should not allow duplicate elementsordered
- true if the collection should iterate over elements in insertion-ordersorted
- true if the collection should iterate over elements in ascending element order,
sorted according to the natural ordering of its elements (see Comparable), or by a Comparator
provided at creation timetrue
if the set of associations
changed as a result of this callpublic boolean associate(InterfaceDescription id, String roleName, Cardinality cardinality, boolean indexed, boolean unique, boolean ordered, boolean sorted)
id
- interface description, must not be nullroleName
- role namecardinality
- cardinality, must not be nullindexed
- true if the collection should be indexedunique
- true if the collection should not allow duplicate elementsordered
- true if the collection should iterate over elements in insertion-ordersorted
- true if the collection should iterate over elements in ascending element order,
sorted according to the natural ordering of its elements (see Comparable), or by a Comparator
provided at creation timetrue
if the set of associations
changed as a result of this callCopyright (c) 2004-2013 held jointly by the individual authors. Licensed under the GNU Lesser General Public License (LGPL).