Hi Jim,
I’ve been
out of the country and unable to evaluate deeply, but it looks good. I’ll
double check everything with the latest version of HOWL (that I proposed (and got
no feedback on)) and then I’ll probably commit the HOWL that should line
up with this latest API revision.
-Paul
From:
higgins-dev-bounces@xxxxxxxxxxx [mailto:higgins-dev-bounces@xxxxxxxxxxx] On Behalf Of Jim Sermersheim
Sent: Thursday, May 10, 2007 11:38
AM
To: higgins-dev@xxxxxxxxxxx
Subject: Re: [higgins-dev] IdAS:
metadata on attribute values
Given that no
objections have surfaced -- especially in light of repeated prompts for
feedback, I assume people are ok with this change.
As this is
holding up the CP-writer's job of implementing updates, I suggest this change
be committed this afternoon. I'll do that unless I hear otherwise.
Jim
>>> "Jim Sermersheim" <jimse@xxxxxxxxxx> 5/9/07 4:16
PM >>>
Two things: 1) I
made a difference between the terms "type" and "ID" in the
proposal below to make more sense.
2) I like this proposal
because it's very familiar to any XML-aware users. A Digital Subject is like an
XML element, and Attributes are like XML sub-elements of the subject element.
Metadata is like XML attributes.
Jim
>>> "Jim Sermersheim" <jimse@xxxxxxxxxx> 5/9/07 3:56
PM >>>
(oops, I didn't
mean to say IMetadataValue extends IValue)
Anyway, now a
small refinement on proposal 3. Here we combine IMetadata and
IMetadataValue, the rest is just like Proposal 3
I think I like
this the best (but I'm assuming people will accept the notion of metadata being
constrained to single, simple values)
Proposal 4:
public interface
IMetadata {
public URI getID() throws IdASException; // the metadata ID
(creationTime, creatorName, etc.)
public URI getType() throws IdASException; // The simple type (string,
integer, etc.)
public String getLexical() throws IdASException;
public String getCanonical() throws IdASException;
public Object getData() throws IdASException;
void setData(Object data) throws IdASException;
void remove() throws IdASException;
public IMetadataModel getModel() throws IdASException;
}
public interface
IHasMetadata {
public
Iterator getMetadataSet() throws IdASException; // Iterator of IMetadata
public
IMetadata getMetadata(URI metadataID) throws IdASException;
IMetadata addMetadata(URI metadataID) throws IdASException,
InvalidMetadataException;
IMetadata
addMetadata(IMetadata copyFrom) throws IdASException;
}
* not
intended to be instantiated (only used as a super-interface)
public interface
IValue extends IHasMetadata {
public boolean isSimple() throws IdASException;
public URI getType() throws IdASException; // like string, int,
address
void remove() throws IdASException;
}
public interface ISimpleValue extends IValue {
public
String getLexical() throws IdASException;
public String getCanonical() throws IdASException;
public Object getData() throws IdASException;
void setData(Object data) throws IdASException;
}
public interface
IComplexValue extends IValue, IHasAttributes {
public interface
IAttribute extends IHasMetadata {
public URI
getAttrID() throws IdASException; // like hobbies, hatSize, homeAddress
public Iterator getValues() throws IdASException;
IValue addValue(URI type) throws IdASException, InvalidTypeException;
IValue addValue(IValue copyFrom) throws IdASException;
ISimpleValue addSimpleValue(URI type, Object data) throws IdASException,
InvalidTypeException;
IComplexValue addComplexValue(URI type) throws IdASException,
InvalidTypeException;
void remove() throws IdASException;
public IAttributeModel getModel() throws IdASException;
public boolean isSingleValued() throws IdASException;
}
public interface
ISingleValuedAttribute extends IAttribute {
public IValue getValue() throws IdASException;
}
public interface
IHasAttributes
{
public Iterator getAttributes() throws IdASException;
public IAttribute getAttribute(URI attrID) throws IdASException;
IAttribute
addAttribute(URI attrID) throws IdASException, InvalidAttributeException;
IAttribute addAttribute(IAttribute copyFrom) throws IdASException;
}
public interface
IDigitalSubject extends IHasMetadata, IHasAttributes
{
public IContext getContext() throws IdASException;
public String
getSubjectID() throws IdASException;
public URI getType() throws IdASException;
void
remove() throws IdASException;
void applyUpdates() throws IdASException; // this is moving to
IContext
public IDigitalSubjectModel getModel() throws IdASException;
}
<snip>
|