Opened 16 years ago
Closed 16 years ago
#160 closed enhancement (fixed)
Find more appropriate names for InvertableMap and DescriptorMap
Reported by: | Alpar Juttner | Owned by: | Balazs Dezso |
---|---|---|---|
Priority: | critical | Milestone: | LEMON 1.1 release |
Component: | core | Version: | hg main |
Keywords: | Cc: | ||
Revision id: |
Description (last modified by )
InvertableMap and DescriptorMap has been removed from the 1.0 release but they are still there in the main branch (as of [1e81878b0e54]).
Attachments (1)
Change History (16)
comment:1 Changed 16 years ago by
Priority: | major → critical |
---|
comment:2 Changed 16 years ago by
Description: | modified (diff) |
---|---|
Summary: | Find more appropriate names for InverseMap and DescriptorMap → Find more appropriate names for InvertableMap and DescriptorMap |
comment:3 Changed 16 years ago by
Status: | new → assigned |
---|
comment:4 follow-up: 5 Changed 16 years ago by
comment:5 follow-up: 6 Changed 16 years ago by
Replying to kpeter:
I think
DescriptorMap
andDescriptorMap::InverseMap
are fully acceptable.
Do you think the DescriptorMap
describes something or give a description of something.
Probably RangeMap
would be a good name. Alas, it is already used. Too bad, what we call now as RangeMap
is also very badly named.
However
InvertableMap
is really misleading.InvertMap
would be much better, but maybe it is too similar toInverseMap
. Or what about names likeReverseMap
,OppositeMap
,BackwardMap
? (I don't even find them so good.)At the moment I think
InvertMap
andInvertMap::InverseMap
would be the best choice.
What about CrossMap
or CrossRefMap
?
comment:6 follow-up: 7 Changed 16 years ago by
Replying to alpar:
Do you think the
DescriptorMap
describes something or give a description of something.
No, but it gives a descriptor for an item. As far as I know this notion is used for something like id, but in this case "id" cannot be used, since the ids of the items can be differ from these descriptors.
Probably
RangeMap
would be a good name.
I don't think so.
Alas, it is already used. Too bad, what we call now as
RangeMap
is also very badly named.
Could you suggest a better name? (Suppose that we don't have to preserve compatibility.)
However
InvertableMap
is really misleading.InvertMap
would be much better, but maybe it is too similar toInverseMap
. Or what about names likeReverseMap
,OppositeMap
,BackwardMap
? (I don't even find them so good.)At the moment I think
InvertMap
andInvertMap::InverseMap
would be the best choice.What about
CrossMap
orCrossRefMap
?
CrossRefMap
is better.
comment:7 Changed 16 years ago by
Replying to kpeter:
Replying to alpar:
Do you think the
DescriptorMap
describes something or give a description of something.No, but it gives a descriptor for an item.
A descriptor is something that describe something else.
As far as I know this notion is used for something like id,
I don't think so.
but in this case "id" cannot be used, since the ids of the items can be differ from these descriptors.
Neither id nor decri* is an appropriate name here, as it fails to express that this tool maps a set of items to a range of integers, which is the main and only purpose of this tool.
Probably
RangeMap
would be a good name.I don't think so.
Why?
Compare it with e.g. BoolMap
, which is used at several places. It maps the items to bools. When we say ReadMap
, then read also refers to the property of the Value
s. But RangeMap
maps from a range. Very confusing, even if we have NodeMap
and EdgeMap
.
Alas, it is already used. Too bad, what we call now as
RangeMap
is also very badly named.Could you suggest a better name?
No, as it is already in LEMON-1.0. Otherwise VectorMap
would be an at least better name.
(Suppose that we don't have to preserve compatibility.)
You wrongly suppose that. I would like to very strictly stick on the rule of backward compatibility, even in case the chance that the change breaks someone's code is very low.
comment:8 follow-up: 9 Changed 16 years ago by
Can we agree in using CrossRefMap
for InvertableMap
?
If yes, the we only need to find a better name for DescriptorMap
comment:9 follow-up: 10 Changed 16 years ago by
Replying to alpar:
Can we agree in using
CrossRefMap
forInvertableMap
?
It seems a good choice.
If yes, the we only need to find a better name for
DescriptorMap
.
What about ContinousIdMap
or maybe MutableIdMap
?
comment:10 follow-up: 11 Changed 16 years ago by
Replying to kpeter:
What about
ContinousIdMap
I prefer ContinuousIdMap?. :)
Otherwise it looks good.
or maybe
MutableIdMap
?
Don't like it. Firstly, IMHO it is not "mutable" but "mutation". Secondly this property is not the feature which we like to use it for, but instead a rather annoying side effect of it.
So, can we say the winners are
ContinuousIdMap
and CrossRefMap
?
comment:11 follow-up: 12 Changed 16 years ago by
Replying to alpar:
So, can we say the winners are
ContinuousIdMap
andCrossRefMap
?
I think, we can. They are much better than the current names.
Anyone else?
comment:12 follow-up: 13 Changed 16 years ago by
Replying to kpeter:
Replying to alpar:
So, can we say the winners are
ContinuousIdMap
andCrossRefMap
?
One more idea. I always have problem with spelling the word "continuous", (and so do Peter :) ). What about using RandeIdMap
instead? (Yes, it is similar to RangeMap
which is something very different, but I don't think it is a problem.)
Changed 16 years ago by
Attachment: | 66969f54d61d.patch added |
---|
comment:13 follow-up: 14 Changed 16 years ago by
Replying to alpar:
One more idea. I always have problem with spelling the word "continuous", (and so do Peter :) ). What about using
RandeIdMap
instead? (Yes, it is similar toRangeMap
which is something very different, but I don't think it is a problem.)
[66969f54d61d] does these renames. Could someone have a look at it?
comment:14 follow-up: 15 Changed 16 years ago by
Replying to alpar:
[66969f54d61d] does these renames. Could someone have a look at it?
There is a strange sentence in the doc: "So, the ids will can change when you deleting an item of the same type.", where both "will can" and "you deleting" seem to be wrong. And a small improvement: also use "\e" before RangeId at lines 2253 and 2255 like the lines 2246 and 2248.
comment:15 Changed 16 years ago by
Resolution: | → fixed |
---|---|
Status: | assigned → closed |
Replying to kpeter:
There is a strange sentence in the doc: "So, the ids will can change when you deleting an item of the same type.", where both "will can" and "you deleting" seem to be wrong. And a small improvement: also use "\e" before RangeId at lines 2253 and 2255 like the lines 2246 and 2248.
Fixed in [be6646ac5d89].
I think
DescriptorMap
andDescriptorMap::InverseMap
are fully acceptable.However
InvertableMap
is really misleading.InvertMap
would be much better, but maybe it is too similar toInverseMap
. Or what about names likeReverseMap
,OppositeMap
,BackwardMap
? (I don't even find them so good.)At the moment I think
InvertMap
andInvertMap::InverseMap
would be the best choice.