Search Mailing List Archives
[protege-discussion] How Does One Retrieve a MetaSlot Value ?
Thomas Russ
tar at ISI.EDU
Mon Jan 22 09:39:17 PST 2007
On Jan 21, 2007, at 8:36 PM, Schultz, Ron wrote:
> I created a MetaSlot class that has the additional property Synonym. I
> did this in the same way recommended on the Wiki for adding a
> Synonym to
> a class, but I extended STANDARD SLOT instead of STANDARD CLASS.
> How do
> I retrieve the synonym for a slot in Java code? Below is the code I
> have
> for doing this to an instance of a class.
It should work the same way. They are, after all, both Frames.
Is that not working for you? What did you try that failed?
BTW, it would be more efficient to get the slot value directly by
using the method KnowledgeBase.getSlot(name) instead of iterating
through all of the own slots and doing a comparison against the
browser text for that slot.
More information about the protege-discussion
mailing list