|
From: <ba...@us...> - 2008-03-13 21:58:37
|
Revision: 9
http://scstudio.svn.sourceforge.net/scstudio/?rev=9&view=rev
Author: babicaj
Date: 2008-03-13 13:56:06 -0700 (Thu, 13 Mar 2008)
Log Message:
-----------
To be more conform to ITU-T specification there were suggested new types of nodes in HMsc: StartNode, EndNode and ReferenceNode. These types have common parent HMscNode. New attributes were added to HMscModification to be more capable to recognize new and removed ReferenceNodes.
Modified Paths:
--------------
trunk/src/data/msc.h
trunk/src/data/msc_modifications.h
Modified: trunk/src/data/msc.h
===================================================================
--- trunk/src/data/msc.h 2008-03-12 20:49:11 UTC (rev 8)
+++ trunk/src/data/msc.h 2008-03-13 20:56:06 UTC (rev 9)
@@ -23,11 +23,13 @@
#include <string>
#include "counted_ptr.h"
-class HmscNode;
+class HMscNode;
+class ReferenceNode;
+class EndNode;
+class StartNode;
class Instance;
class Event;
class Msc;
-class HmscNode;
class BMsc;
class MscMessage;
class EventArea;
@@ -38,9 +40,13 @@
typedef counted_ptr<BMsc> BMscPtr;
-typedef counter_ptr<HmscNode> HmscNodePtr;
-typedef std::list<HmscNodePtr> HmscNodePtrList;
+typedef counter_ptr<ReferenceNode> ReferenceNodePtr;
+typedef std::list<ReferenceNodePtr> ReferenceNodePtrList;
+typedef counter_ptr<StartNode> StartNodePtr;
+
+typedef counter_ptr<EndNode> EndNodePtr;
+
typedef counted_ptr<Instance> InstancePtr;
typedef std::list<InstancePtr> InstancePtrList;
@@ -90,23 +96,71 @@
{
/**
- * Start nodes of HMsc.
+ * Start node of HMsc.
+ *
+ * Mandatory element in HMsc, should be initialized in constructor.
*/
- HmscNodePtrList m_start_nodes;
+ StartNodePtr m_start;
+
+ /**
+ * All ReferenceNodes of HMsc.
+ */
+ ReferenceNodePtrList m_nodes;
};
-class HmscNode
+/**
+ * Base abstract class for node of HMsc
+ */
+class HMscNode{
+
+};
+
+/**
+ * Start node of HMsc.
+ *
+ * According to ITU-T standard, each HMsc has got exactly
+ * one start node.
+ */
+class StartNode:public HMscNode
{
+
+ /**
+ * Succesors of StartNode.
+ */
+ ReferenceNodePtrList m_successors;
+};
+
+/**
+ * End node of HMsc.
+ */
+class EndNode:public HMscNode
+{
+
+
+};
+
+/**
+ * HMscNode which references either BMsc or HMsc.
+ */
+class ReferenceNode:public HMscNode
+{
+
/**
- * Succesors of HmscNode
+ * Succesors of ReferenceNode.
*/
- HmscNodePtrList m_successors;
+ ReferenceNodePtrList m_successors;
/**
- * MSC which is contained in this node
+ * MSC which is contained in this node.
*/
MscPtr m_msc;
+
+ /**
+ * EndNode which this ReferenceNode is connected to,
+ * NULL if there isn't any such connection.
+ */
+ EndNodePtr m_end;
};
/**
Modified: trunk/src/data/msc_modifications.h
===================================================================
--- trunk/src/data/msc_modifications.h 2008-03-12 20:49:11 UTC (rev 8)
+++ trunk/src/data/msc_modifications.h 2008-03-13 20:56:06 UTC (rev 9)
@@ -137,7 +137,7 @@
/**
* Modified InstanceArea.
*/
- InstanceAreaPtrList m_modified_instance_area;
+ InstanceAreaPtr m_modified_area;
};
@@ -165,28 +165,28 @@
};
/**
- * Modification of HMscNode.
+ * Modification of ReferenceNode.
*/
-class HMscNodeModification: public MscModification
+class ReferenceNodeModification: public MscModification
{
/**
- * Previous version of HMscNode.
+ * Previous version of ReferenceNode.
*/
- HMscNodePtr m_previous;
+ ReferenceNodePtr m_previous;
/**
* Removed successors.
*/
- std::set<HMscNodePtr> m_removed_successors;
+ std::set<ReferenceNodePtr> m_removed_successors;
/**
* New successors.
*/
- std::set<HMscNodePtr> m_new_successors;
+ std::set<ReferenceNodePtr> m_new_successors;
/**
- * Changed Msc of the HMscNode.
+ * Changed Msc of the ReferenceNode.
*
* If NULL then Msc points to the same one (doesn't care if it was
* internally modified).
@@ -205,15 +205,25 @@
HMscPtr m_previous;
/**
- * Removed start nodes.
+ * Removed successors of StartNode.
*/
- std::set<HMscNodePtr> m_removed_start_nodes;
+ std::set<ReferenceNodePtr> m_removed_beginners;
/**
- * New start nodes.
+ * New successors of StartNode.
*/
- std::set<HMscNodePtr> m_new_start_nodes;
+ std::set<ReferenceNodePtr> m_new_beginners;
+ /**
+ * Removed nodes.
+ */
+ std::set<ReferenceNodePtr> m_removed_nodes;
+
+ /**
+ * New nodes.
+ */
+ std::set<ReferenceNodePtr> m_new_nodes;
+
}
#endif /* _MSC_MODIFICATIONS_H */
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|