Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 344409 - Add @Transient and @Embedded attributes and use in XGCONF
Summary: Add @Transient and @Embedded attributes and use in XGCONF
Status: ASSIGNED
Alias: None
Product: RTSC
Classification: Technology
Component: Core (show other bugs)
Version: unspecified   Edit
Hardware: PC All
: P3 normal (vote)
Target Milestone: ---   Edit
Assignee: Dave Russo CLA
QA Contact:
URL:
Whiteboard:
Keywords:
: 350744 (view as bug list)
Depends on:
Blocks:
 
Reported: 2011-05-02 01:15 EDT by Jon Rowlands CLA
Modified: 2014-01-22 17:29 EST (History)
3 users (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Jon Rowlands CLA 2011-05-02 01:15:53 EDT
XGCONF currently uses a private file "non-api.txt" in a certain directory
to add tags that tell XGCONF how to write changes to specific config params
into the .cfg script. The tags let content authors improve the robustness
and readability of user .cfg scripts.

This bug addresses making these tags available to any content, by adding
attributes to the XDCspec language and recognizing those in XGCONF. The two
new tags are @Transient and @Embedded, and can be applied only to config
params.

@Transient indicates that the config param should never be written to the
.cfg script. It implies that the .cfg param is for internal use only and
is recomputed from scratch in each execution of the .cfg script. The benefit
is that the config param may be redefined or removed in later product
releases with no harm to existing user .cfg scripts.

@Embedded applies only to config params that hold a reference to a spec'd
object. Typically the config param has a declared type of Any, or XXX.Instance,
XXX.Module, or Struct XXX. It indicates that the config param is the preferred
name in user .cfg scripts for an otherwise internal object. The referenced
object is considered to be nested (embedded) within the parent object, rather
than just referenced. If multiple config params declare themselves to be the
preferred name for a referenced object, the result is implementation dependent,
though XGCONF will use best effort to resolve the ambiguity in context upon
each use.

The existing way of declaring these tags should be kept to ease transition.
Comment 1 Dave Russo CLA 2011-11-25 19:48:58 EST
*** Bug 350744 has been marked as a duplicate of this bug. ***
Comment 2 Dave Russo CLA 2012-07-23 20:38:55 EDT
small progress in xdctools 3.24: Added @Transient to individual config parameters in xdc.services.spec and corresponding support in xgconf.  

We should probably also add support for module-wide declarations that allow specification of regexps that identify transient configs (as we do in non_api.txt).

@Embedded has not yet been implemented.