Customizing association accessors

 

Introduction

Each class that parameterizes the accessors for an association must contain an operation named "declare", used to generate the declaration of the corresponding Java attribute.

 

The other operations are used to generate attribute or association accessors according to the access mode of their attribute or association.

 

For associations, one of them must generate an accessor named "card" that returns an integer containing the association's current multiplicity.

 

 

Customizing the methods of the simpleAssociation class

 

The ... method

is used to customize ...

declare

the declaration of the Java attribute.

get

the access to the Java attribute.

set

the modification of the Java attribute.

card

the calculation of the number of elements.

 

 

Customizing the methods of the vectorMutipleAssociation class

 

The ... method

is used to customize ...

declare

the declaration of the Java attribute.

get

the access to an element with a given index.

set

the substitution of the element with a given index.

append

the addition of an element.

erase_by_element

the deletion of a given element.

erase_by_index

the deletion of an element with a given index.

card

the calculation of the number of elements.

 

 

Customizing the methods of the vectorFiniteAssociation class

 

The ... method

is used to customize ...

declare

the declaration of the Java attribute.

get

the access to an element with the given index.

set

the substitution of the element with a given index.

append

the addition of an element.

erase_by_element

the deletion of a given element.

erase_by_index

the deletion of an element with a given index.

card

the calculation of the number of elements.

 

 

Customizing the methods of the arrayFiniteAssociation class

 

The ... method

is used to customize ...

declare

the declaration of the Java attribute.

get

the access to an element with a given index.

get_all

the access to all the elements.

set

the modification of the element with the given index.

set_all

the modification of all the elements.

card

the calculation of the number of elements.

 

 

Customizing the methods of the stackMultipleAssociation class

 

The ... method

is used to customize ...

declare

the declaration of the Java attribute.

get

the access to the element on top of the stack.

append

the addition of an element.

erase

the deletion of an element on top of the stack.

card

the calculation of the number of elements.

 

 

Customizing the methods of the stackFiniteAssociation class

 

The ... method

is used to customize ...

declare

the declaration of the Java attribute.

get

the access of the element on top of the stack.

append

the addition of an element.

erase

the deletion of an element on top of the stack.

card

the calculation of the number of elements.

 

 

Customizing the methods of the hashtableMultipleAssociation class

 

The ... method

is used to customize ...

declare

the declaration of the attribute.

get

the access to an element from its key.

append

the addition of an element with its key.

erase_by_key

the deletion of an element from its key.

card

the calculation of the number of elements.