Mark Hammond wrote:
> Tobias Oberstein wrote:
>
>> With parameters in ContractIDs I mean something like this:
>>
>> "@xyz.com/some-module/foobar;1?param1=small;param2=blue"
>>
>> where param1 and param2 can take values of some predefined
>>
>> sets {'small', 'medium', 'big'} and {'red', 'blue'}.
>
>
> It is not clear what you are asking. contract IDs are unique(ish)
> strings. For every known contract ID, there is a class ID, which
> uniquely identifies a component, as implemented in some source file
> (generally .c/cpp or .js)
What I think he wants is a way to specify initial state or some values
to use for initialization in the contract ID.
@myclass?param1=one;param2=two
@myclass?param1=three;param2=four
He's saying this equates to the same component "myclass". And I assume
would call some predetermined function that would process the rest of
the contract ID and do some initialization.
It'd be much like creating an instance and then calling
object.Init("one", "two");
Neither XPCOM nor COM does this and IMO its not a good idea.