Hello again,
I'm glad my previous RoseScript was useful to you. Adding
dependencies is actually a bit easier, depending on what kind of dependency
we are talking about. For example, in the following sample script, a
dependency relationship is created between two classes in a class diagram:
Sub Main
Dim cat As Category
Dim diag As ClassDiagram
Dim dep As ClassDependency
Dim c1 As Class
Dim c2 As Class
Set cat = Roseapp.CurrentModel.RootCategory.AddCategory("Stooges")
Set diag = cat.AddClassDiagram("StoogesDiagram")
Set c1 = cat.AddClass("Larry")
Set c2 = cat.AddClass("Curley")
'How to add a class dependency
'To add other relations, see help topic "Class class methods"
Set dep = c1.addClassDependency("slaps","Curley")
'adding classes two the diagram
x = diag.AddClass(c1)
x = diag.AddClass(c2)
diag.Activate
End Sub
Hope this helps,
Thank you,
Shaquille Asghari
Senior Support Engineer
Rational Customer Service - Committed to Service Excellence
SCP Certified:- http://www.rational.com/support/scp.jsp
Rational
the software development company
==========Original Messege==========
-----Original Message-----
From: Nikolay Alexiev [mailto:[EMAIL PROTECTED]]
Sent: Wednesday, February 20, 2002 12:18 AM
To: rational
Subject: (ROSE) Dependency or Instantiates
You help me with Dependency and thanks for that. But
when I get AllDependency I generate new problem. How
can add DependencyRelation to RoseElement?
__________________________________________________
Do You Yahoo!?
Yahoo! Sports - Coverage of the 2002 Olympic Games
http://sports.yahoo.com
************************************************************************
* Rose Forum is a public venue for ideas and discussions.
* For technical support, visit http://www.rational.com/support
*
* Post or Reply to: [EMAIL PROTECTED]
* Subscription Requests: [EMAIL PROTECTED]
* Archive of messages:
* http://www.rational.com/support/usergroups/rose/rose_forum.jsp
* Other Requests: [EMAIL PROTECTED]
*
* To unsubscribe from the list, please send email
* To: [EMAIL PROTECTED]
* Subject: <BLANK>
* Body: unsubscribe rose_forum
*************************************************************************
************************************************************************
* Rose Forum is a public venue for ideas and discussions.
* For technical support, visit http://www.rational.com/support
*
* Post or Reply to: [EMAIL PROTECTED]
* Subscription Requests: [EMAIL PROTECTED]
* Archive of messages:
* http://www.rational.com/support/usergroups/rose/rose_forum.jsp
* Other Requests: [EMAIL PROTECTED]
*
* To unsubscribe from the list, please send email
* To: [EMAIL PROTECTED]
* Subject: <BLANK>
* Body: unsubscribe rose_forum
*************************************************************************