>
>
>
> Before making any changes (WINK-10), I want to make sure I understand some
> of the semantics of the code correctly.
>
> org.apache.wink.common.internal.registry.metadata.ClassMetadata   --  This
> is meant to model ANY class that would be used in a JAX-RS application
> (root resource, sub resource, provider, etc.).  It is THE ultimate holder
> of generic information on what needs to be injected and how to create
> instances of the class.  Is that correct?
>

Correct. Just one clarification: ClassMetadata contains ConstructorMetadata
that contains the information how to create the class (which constructor to
use and what are the parameters to inject), but it doesn't define the life
cycle of the object. Meaning, it's not enough to look at the ClassMetadata
in order to know how exactly the object will be created.


> org.apache.wink.common.internal.registry.metadta.*Collector  --  These
> classes are responsible for building the metadata instances.
>

Correct.


> org.apache.wink.server.internal.registry.*Record  --  These objects are
> created as root resource and provider instances are added to the config.
> They are added to the registry which represents the config for the entire
> set of resources available in the application.
>

Almost correct: The *Record classes are used only for resources
(root-resources, sub-resource locators, sub-resource methods and so on).
They are NOT used by the providers.


>
>
> I like the breakdown/organization of those parts.  Just trying to make sure
> the semantics are clear.
>
> So, as a general prinicple, if we're going to affect how things are
> represented to the runtime, getting the information we need in one of the
> Collectors should be the first choice.  The ClassMetadata instances are
> immutable once they've been added to the config, correct?
>

Correct.

>
>
> -Nick
>
>
>
>
> Nicholas Gallardo
> WebSphere  - REST & WebServices Development
> [email protected]
> Phone: 512-286-6258
> Building: 903 / 5G-016

Reply via email to