Skip to main content

Notice: This Wiki is now read only and edits are no longer possible. Please see: https://gitlab.eclipse.org/eclipsefdn/helpdesk/-/wikis/Wiki-shutdown-plan for the plan.

Jump to: navigation, search

IdAS Update Proposals 2

Revision as of 09:49, 17 April 2007 by Unnamed Poltroon (Talk) (New page: There was three problems in the previous IdAS model: 1. Attribute (IProperty) has two methods - getValues() and getValue(), and can store/return as single value as multiple value. We pr...)

(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)

There was three problems in the previous IdAS model:

1. Attribute (IProperty) has two methods - getValues() and getValue(), and can store/return as single value as

multiple value. We propose to add the following changes to IdAS interfaces to remove this ambiguity:

interface IPropertyValue {

         boolean isSingle();
         boolean isComplex();
         boolean isList();
         URI getType();

}

interface ISimpleValue extends IPripertyValue {

         Object getValue();
         void setValue(Object value);

}

interface IComplexValue extends IPropertyValue, IHasProperties { }

interface IValueList extends IPropertyValue {

         Iterator getValues();
         void setValues(Iterator newValues);
         void addValue(IPropertyValue value);
         void removeValue(IPropertyValue value);

}

interface IProperty {

         IPropertyValue getValue();
         void setValue(IPropertyValue value);

}

By default IAttribute (IProperty) should retrun IValueList instance. If we want to define this attribute as single. We should set cardinality = 1 for appropriate attribute property in the higgins-OWL schema and in this case IProperty should return single ISimpleValue or IComplexValue instance. As result using cardinality mechanism in higgins schema we will define which value is used for attribute single or multiple.


2. Complex Attriburte can not contain more than one complex value because of restrictions of used OWL schema. Figure below shows current schema:


ComplexValueCurrent.jpg

We need to add some intermediary owl-class between pwa:postalAddress (attribute property of subject) and pwa:PostalAddress (complex value class), like pwa:postalAddress_container on the figure below.

ComplexValueProposed.jpg


3. We need some transaction mechanism to update IContext (or IDigitalSubject at the least) safely. I think it will be most useful to add transaction support on IContext level. We propose to add the following methods:

a) commit() - this method will be used by user to commit a set of changes made in the context; b) rollback() - this method will be used by user to rollback his changes for some resons (non-IdAS exeptions); c) setAutocommit(boolean) - this method will be used by user to set\reset transaction mode (if true - user should use commit() method to save changes, if false - each change will be saved immediately).

Back to the top