All Downloads are FREE. Search and download functionalities are using the official Maven repository.

org.nakedobjects.metamodel.spec.feature.NakedObjectAssociationContainer Maven / Gradle / Ivy

The newest version!
package org.nakedobjects.metamodel.spec.feature;

import java.util.List;

import org.nakedobjects.metamodel.commons.filters.Filter;
import org.nakedobjects.metamodel.commons.filters.Filters;


public interface NakedObjectAssociationContainer {

    /**
     * Get the field object representing the field with the specified field identifier.
     */
    NakedObjectAssociation getAssociation(String id);

    /**
     * Return all the fields that exist in an object of this specification, although they need not all be
     * accessible or visible.
     */
    NakedObjectAssociation[] getAssociations();

    /**
     * As per {@link #getAssociations()}, but returning a {@link List}.
     * @return
     */
    List getAssociationList();

    /**
     * Return all {@link NakedObjectAssociation}s matching the supplied filter.
     * 
     * To get the statically visible fields (where any invisible and unauthorised fields have been removed)
     * use NakedObjectAssociationFilters#STATICALLY_VISIBLE_ASSOCIATIONS
     * 
     * @see Filters
     */
    NakedObjectAssociation[] getAssociations(Filter filter);

    /**
     * As per {@link #getAssociations(Filter)}, but returning a {@link List}.
     * @return
     */
    List getAssociationList(Filter filter);

    /**
     * All {@link NakedObjectAssociation association}s that represent {@link OneToOneAssociation properties}.
     */
    List getPropertyList();

    /**
     * All {@link NakedObjectAssociation association}s that represents {@link OneToManyAssociation collections}. 
     * @return
     */
    List getCollectionList();


}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy