[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]

Re: Restricting possible connections



On Fri, 25 Oct 2002, ed hunter wrote:
> On Thu, Oct 24, 2002 at 06:36:19PM +0200, ml wrote:
>> OK, I try to resume:
>> 
>> 1. A restriction on possible connections seems to be a good
>>    idea.  Think of network diagrams, not to speak of
>>    UML/Database/SDL/... code generation.
>> 
>> 2. Of course, this must be an option to the user.  Maybe a
>>    diagram specific or a global option?
>> 
>> 3. The method to check has to be a new object function.
>>    Something like:
>> 
>>    typedef gboolean (*AllowConnectFunc) (Object* obj_me,
>>                                          Object* obj_other,
>>                                          ... /* ? */ );
> 
> It should also say whether the called object is the source or the
> destination.  e.g. gboolean is_source
> 
> Now thinking of it ....
> 
> The problem is even more hairy, since also the connection can be an
> object, right?  So in general, the function has to be called three times
> and their args should contain all three objects and their handles

I don't see what you mean... both elements (Class, Box etc) and connections
(Inheritance, Line etc) are objects.  Those are the only two objects that
should be called upon.  Now if the object wants to check what's at the
other end of a line... we need to make sure we can do that.

-Lars

-- 
Lars Clausen (http://shasta.cs.uiuc.edu/~lrclause)| Hårdgrim of Numenor
"I do not agree with a word that you say, but I   |----------------------------
will defend to the death your right to say it."   | Where are we going, and
    --Evelyn Beatrice Hall paraphrasing Voltaire  | what's with the handbasket?



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index] Mail converted by Mofo Magic and the Flying D

 
All trademarks and copyrights are the property of their respective owners.

Other Directory Sites: SeekWonder | Directory Owners Forum

GuideSMACK