#mooseName and fully qualified name?

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
5 messages Options
Reply | Threaded
Open this post in threaded view
|

#mooseName and fully qualified name?

abergel
Hi!

[context: I am reviving CAnalyzer. My goal is to have it part of Moose for good. ]

At the time I worked on it, we had mooseName that return the fully qualified name (e.g., 'file2.hunit.recGlobal'). This was quite handy to lookup value. For example, I could write:

 mooseModel entityNamed: 'file2.hunit.recGlobal'

this will return the definition of recGlobal defined in the file2.h.

Apparently, mooseName now returns the name (a String) as a symbol.
The method printOn: return the fully qualified name.

We had some discussion some times ago, but I kind of forgot what the motivation was for that change.
Should't we have a way to fully quality entities?

Cheers,
Alexandre

--
_,.;:~^~:;._,.;:~^~:;._,.;:~^~:;._,.;:~^~:;._,.;:
Alexandre Bergel  http://www.bergel.eu
^~:;._,.;:~^~:;._,.;:~^~:;._,.;:~^~:;._,.;:~^~:;.





_______________________________________________
Moose-dev mailing list
[hidden email]
https://www.iam.unibe.ch/mailman/listinfo/moose-dev
Reply | Threaded
Open this post in threaded view
|

Re: #mooseName and fully qualified name?

Tudor Girba-2
Hi Alex,

I think I do not understand your mail :).

mooseName should be a fully qualified unique name as often as possible. It is definitely intended to be used like you mentioned in your mail (e.g., using entityNamed:).

So, where do you see mooseName returning the name only?

Cheers,
Doru



On 1 Oct 2011, at 18:19, Alexandre Bergel wrote:

> Hi!
>
> [context: I am reviving CAnalyzer. My goal is to have it part of Moose for good. ]
>
> At the time I worked on it, we had mooseName that return the fully qualified name (e.g., 'file2.hunit.recGlobal'). This was quite handy to lookup value. For example, I could write:
>
> mooseModel entityNamed: 'file2.hunit.recGlobal'
>
> this will return the definition of recGlobal defined in the file2.h.
>
> Apparently, mooseName now returns the name (a String) as a symbol.
> The method printOn: return the fully qualified name.
>
> We had some discussion some times ago, but I kind of forgot what the motivation was for that change.
> Should't we have a way to fully quality entities?
>
> Cheers,
> Alexandre
>
> --
> _,.;:~^~:;._,.;:~^~:;._,.;:~^~:;._,.;:~^~:;._,.;:
> Alexandre Bergel  http://www.bergel.eu
> ^~:;._,.;:~^~:;._,.;:~^~:;._,.;:~^~:;._,.;:~^~:;.
>
>
>
>
>
> _______________________________________________
> Moose-dev mailing list
> [hidden email]
> https://www.iam.unibe.ch/mailman/listinfo/moose-dev

--
www.tudorgirba.com

"If you interrupt the barber while he is cutting your hair,
you will end up with a messy haircut."


_______________________________________________
Moose-dev mailing list
[hidden email]
https://www.iam.unibe.ch/mailman/listinfo/moose-dev
Reply | Threaded
Open this post in threaded view
|

Re: #mooseName and fully qualified name?

Stéphane Ducasse

mooseName
        "Returns an unique identifier of this entity.  This method is mandatory, and must
        return a Symbol or Integer that uniquely identifies this entity within its model (but
        not within the entire Moose enivronment, see MooseElement>>mooseID). The return
        value must not be nil, and must never change. The implementation should be fast,
        as this key may be used extensivley by the MooseModel or similar facilities."

        mooseName was uniqueName in previous versions.?

On Oct 2, 2011, at 8:36 AM, Tudor Girba wrote:

> Hi Alex,
>
> I think I do not understand your mail :).
>
> mooseName should be a fully qualified unique name as often as possible. It is definitely intended to be used like you mentioned in your mail (e.g., using entityNamed:).
>
> So, where do you see mooseName returning the name only?
>
> Cheers,
> Doru
>
>
>
> On 1 Oct 2011, at 18:19, Alexandre Bergel wrote:
>
>> Hi!
>>
>> [context: I am reviving CAnalyzer. My goal is to have it part of Moose for good. ]
>>
>> At the time I worked on it, we had mooseName that return the fully qualified name (e.g., 'file2.hunit.recGlobal'). This was quite handy to lookup value. For example, I could write:
>>
>> mooseModel entityNamed: 'file2.hunit.recGlobal'
>>
>> this will return the definition of recGlobal defined in the file2.h.
>>
>> Apparently, mooseName now returns the name (a String) as a symbol.
>> The method printOn: return the fully qualified name.
>>
>> We had some discussion some times ago, but I kind of forgot what the motivation was for that change.
>> Should't we have a way to fully quality entities?
>>
>> Cheers,
>> Alexandre
>>
>> --
>> _,.;:~^~:;._,.;:~^~:;._,.;:~^~:;._,.;:~^~:;._,.;:
>> Alexandre Bergel  http://www.bergel.eu
>> ^~:;._,.;:~^~:;._,.;:~^~:;._,.;:~^~:;._,.;:~^~:;.
>>
>>
>>
>>
>>
>> _______________________________________________
>> Moose-dev mailing list
>> [hidden email]
>> https://www.iam.unibe.ch/mailman/listinfo/moose-dev
>
> --
> www.tudorgirba.com
>
> "If you interrupt the barber while he is cutting your hair,
> you will end up with a messy haircut."
>
>
> _______________________________________________
> Moose-dev mailing list
> [hidden email]
> https://www.iam.unibe.ch/mailman/listinfo/moose-dev


_______________________________________________
Moose-dev mailing list
[hidden email]
https://www.iam.unibe.ch/mailman/listinfo/moose-dev
Reply | Threaded
Open this post in threaded view
|

Re: #mooseName and fully qualified name?

Tudor Girba-2
Yes, it comes from uniqueName. After uniqueName it became mooseUniqueName, and now it is mooseName.

Doru


On 2 Oct 2011, at 12:45, Stéphane Ducasse wrote:

>
> mooseName
> "Returns an unique identifier of this entity.  This method is mandatory, and must
> return a Symbol or Integer that uniquely identifies this entity within its model (but
> not within the entire Moose enivronment, see MooseElement>>mooseID). The return
> value must not be nil, and must never change. The implementation should be fast,
> as this key may be used extensivley by the MooseModel or similar facilities."
>
> mooseName was uniqueName in previous versions.?
>
> On Oct 2, 2011, at 8:36 AM, Tudor Girba wrote:
>
>> Hi Alex,
>>
>> I think I do not understand your mail :).
>>
>> mooseName should be a fully qualified unique name as often as possible. It is definitely intended to be used like you mentioned in your mail (e.g., using entityNamed:).
>>
>> So, where do you see mooseName returning the name only?
>>
>> Cheers,
>> Doru
>>
>>
>>
>> On 1 Oct 2011, at 18:19, Alexandre Bergel wrote:
>>
>>> Hi!
>>>
>>> [context: I am reviving CAnalyzer. My goal is to have it part of Moose for good. ]
>>>
>>> At the time I worked on it, we had mooseName that return the fully qualified name (e.g., 'file2.hunit.recGlobal'). This was quite handy to lookup value. For example, I could write:
>>>
>>> mooseModel entityNamed: 'file2.hunit.recGlobal'
>>>
>>> this will return the definition of recGlobal defined in the file2.h.
>>>
>>> Apparently, mooseName now returns the name (a String) as a symbol.
>>> The method printOn: return the fully qualified name.
>>>
>>> We had some discussion some times ago, but I kind of forgot what the motivation was for that change.
>>> Should't we have a way to fully quality entities?
>>>
>>> Cheers,
>>> Alexandre
>>>
>>> --
>>> _,.;:~^~:;._,.;:~^~:;._,.;:~^~:;._,.;:~^~:;._,.;:
>>> Alexandre Bergel  http://www.bergel.eu
>>> ^~:;._,.;:~^~:;._,.;:~^~:;._,.;:~^~:;._,.;:~^~:;.
>>>
>>>
>>>
>>>
>>>
>>> _______________________________________________
>>> Moose-dev mailing list
>>> [hidden email]
>>> https://www.iam.unibe.ch/mailman/listinfo/moose-dev
>>
>> --
>> www.tudorgirba.com
>>
>> "If you interrupt the barber while he is cutting your hair,
>> you will end up with a messy haircut."
>>
>>
>> _______________________________________________
>> Moose-dev mailing list
>> [hidden email]
>> https://www.iam.unibe.ch/mailman/listinfo/moose-dev
>
>
> _______________________________________________
> Moose-dev mailing list
> [hidden email]
> https://www.iam.unibe.ch/mailman/listinfo/moose-dev

--
www.tudorgirba.com

"We are all great at making mistakes."








_______________________________________________
Moose-dev mailing list
[hidden email]
https://www.iam.unibe.ch/mailman/listinfo/moose-dev
Reply | Threaded
Open this post in threaded view
|

Re: #mooseName and fully qualified name?

abergel
In reply to this post by Tudor Girba-2
Hi!

Sorry, I did not carefully see parentPackage and parentScope.
Nevermind.

Cheers,
Alexandre


On 2 Oct 2011, at 03:36, Tudor Girba wrote:

> Hi Alex,
>
> I think I do not understand your mail :).
>
> mooseName should be a fully qualified unique name as often as possible. It is definitely intended to be used like you mentioned in your mail (e.g., using entityNamed:).
>
> So, where do you see mooseName returning the name only?
>
> Cheers,
> Doru
>
>
>
> On 1 Oct 2011, at 18:19, Alexandre Bergel wrote:
>
>> Hi!
>>
>> [context: I am reviving CAnalyzer. My goal is to have it part of Moose for good. ]
>>
>> At the time I worked on it, we had mooseName that return the fully qualified name (e.g., 'file2.hunit.recGlobal'). This was quite handy to lookup value. For example, I could write:
>>
>> mooseModel entityNamed: 'file2.hunit.recGlobal'
>>
>> this will return the definition of recGlobal defined in the file2.h.
>>
>> Apparently, mooseName now returns the name (a String) as a symbol.
>> The method printOn: return the fully qualified name.
>>
>> We had some discussion some times ago, but I kind of forgot what the motivation was for that change.
>> Should't we have a way to fully quality entities?
>>
>> Cheers,
>> Alexandre
>>
>> --
>> _,.;:~^~:;._,.;:~^~:;._,.;:~^~:;._,.;:~^~:;._,.;:
>> Alexandre Bergel  http://www.bergel.eu
>> ^~:;._,.;:~^~:;._,.;:~^~:;._,.;:~^~:;._,.;:~^~:;.
>>
>>
>>
>>
>>
>> _______________________________________________
>> Moose-dev mailing list
>> [hidden email]
>> https://www.iam.unibe.ch/mailman/listinfo/moose-dev
>
> --
> www.tudorgirba.com
>
> "If you interrupt the barber while he is cutting your hair,
> you will end up with a messy haircut."
>
>
> _______________________________________________
> Moose-dev mailing list
> [hidden email]
> https://www.iam.unibe.ch/mailman/listinfo/moose-dev

--
_,.;:~^~:;._,.;:~^~:;._,.;:~^~:;._,.;:~^~:;._,.;:
Alexandre Bergel  http://www.bergel.eu
^~:;._,.;:~^~:;._,.;:~^~:;._,.;:~^~:;._,.;:~^~:;.





_______________________________________________
Moose-dev mailing list
[hidden email]
https://www.iam.unibe.ch/mailman/listinfo/moose-dev