Search Mailing List Archives

Limit search to: Subject & Body Subject Author
Sort by: Reverse Sort
Limit to: All This Week Last Week This Month Last Month
Select Date Range     through    

[protege-discussion] Programmatically override the maximum cardinality for a slot, varying it by Cls

Thomas Russ tar at
Mon Oct 25 11:09:26 PDT 2010

On Oct 24, 2010, at 7:28 PM, Ron Schultz wrote:

> I have a circumstance where different Clses contain the slot  
> 'keyword.' The keyword slot is of valueType 'String,' with a default  
> maximum cardinality set to 1.
> I have a requirement to vary this cardinality class by class. I am  
> just not sure how to do this programmatically.
> Let's say I have a class 'Article' where I want to set the maximum  
> number of keywords to 5.
> Do I:
> 	• Get the slot 'keywords' from the cls 'Article', and then set the  
> values of keyword's slot named :SLOT-MAXIMUM-CARDINALITY to a  
> Collection containing 5?
> 	• Or do I perform some operations using the facets of the slot  
> 'keyword.'
> 	• Or ...?
> I've spent all weekend trying to figure this out and I know I must  
> be missing something obvious.

Not completely sure about this, but it looks like this may be what you  
are looking for:

More information about the protege-discussion mailing list