Skip to main content

Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Archived » Sapphire » @possiblevalues annotation for ImpliedElementProperty
@possiblevalues annotation for ImpliedElementProperty [message #1707188] Wed, 02 September 2015 23:14 Go to next message
Eclipse UserFriend

Is there any way to use
@possiblevalues( property = "/path/to/a/ImpliedElementProperty")
on a ImpliedElementProperty. For example I have

@Type(base = Name.class)
ImpliedElementProperty PROP_AUTHOR_NAME = new ImpliedElementProperty(TYPE, "AuthorName");

where name.class has 3 Value<String> - firstName, middleName, and lastName. I want to create a CONTACT_NAME property which is also of the same base type Name.class and make it refer to author names. But I am not able to use @possiblevalues to say that the CONTACT_NAME should be a valid AUTHOR_NAME

Re: @possiblevalues annotation for ImpliedElementProperty [message #1707192 is a reply to message #1707188] Thu, 03 September 2015 02:29 Go to previous messageGo to next message
Konstantin Komissarchik is currently offline Konstantin KomissarchikFriend
Messages: 1077
Registered: July 2009
Senior Member
You can't use @PossibleValues to populate multiple value properties at once. It can only be associated with a single value property.

Best you can do is something similar to the way city/state/zip is handled in the contacts sample with three separate inter-dependent PossibleValueService implementations. So if the user types in "John" as first name, they can browse last names of authors with that first name.

[Updated on: Thu, 03 September 2015 02:35]

Report message to a moderator

Re: @possiblevalues annotation for ImpliedElementProperty [message #1707331 is a reply to message #1707192] Thu, 03 September 2015 18:54 Go to previous message
Eclipse UserFriend
Thank you for the quick response. I will check the possibleValueService implementations of city/state/zip in sapphire samples.
Previous Topic:Sapphire repositories now include .pack.gz files
Next Topic:Outline view gets minimized with no node selection and hence a empty form
Goto Forum:

Current Time: Wed Jul 24 12:35:10 GMT 2024

Powered by FUDForum. Page generated in 0.03524 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top