// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
-// See http://www.opencascade.org/SALOME/ or email : webmaster.salome@opencascade.org
+// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
//
//
//
// $Header$
/*! \mainpage
- \image html Application-About.png
+ \image html Application-About1.jpg
*/
/*!
#define _SALOMEDS_IDL_
#include "SALOME_Exception.idl"
+#include "SALOME_GenericObj.idl"
/*!
This package contains the interfaces used for creation, managment
interface ChildIterator;
interface Driver;
interface AttributeStudyProperties;
+ interface AttributeParameter;
interface UseCaseIterator;
interface UseCaseBuilder;
- interface Callback;
/*! List of attributes of %SObjects
*/
\param aComponentName It's a string value in the Comment Attribute of the Component,
which is looked for, defining the data type of this Component.
-<BR><VAR>See also <A href=exemple/Example1.html> an example </A> of this method usage in batchmode of %SALOME application.</VAR>
+<BR><VAR>See also <A href="exemple/Example1.html"> an example </A> of this method usage in batchmode of %SALOME application.</VAR>
*/
SComponent FindComponent (in string aComponentName);
/*!
\param anObjectName String parameter defining the name of the object
\return The obtained %SObject
-<BR><VAR>See also <A href=exemple/Example19.html> an example </A> of this method usage in batchmode of %SALOME application.</VAR>
+<BR><VAR>See also <A href="exemple/Example19.html"> an example </A> of this method usage in batchmode of %SALOME application.</VAR>
*/
SObject FindObject (in string anObjectName);
Sets the context of the %Study.
\param thePath String parameter defining the context of the study.
-<BR><VAR>See also <A href=exemple/Example23.html> an example </A> of this method usage in batchmode of %SALOME application.</VAR>
+<BR><VAR>See also <A href="exemple/Example23.html"> an example </A> of this method usage in batchmode of %SALOME application.</VAR>
*/
void SetContext(in string thePath);
/*!
Gets the context of the %Study.
-<BR><VAR>See also <A href=exemple/Example23.html> an example </A> of this method usage in batchmode of %SALOME application.</VAR>
+<BR><VAR>See also <A href="exemple/Example23.html"> an example </A> of this method usage in batchmode of %SALOME application.</VAR>
*/
string GetContext();
\return A new %StudyBuilder.
-<BR><VAR>See also <A href=exemple/Example20.html> an example </A> of this method usage in batchmode of %SALOME application.</VAR>
+<BR><VAR>See also <A href="exemple/Example20.html"> an example </A> of this method usage in batchmode of %SALOME application.</VAR>
*/
StudyBuilder NewBuilder() ;
Returns the attriubte, which contains the properties of this study.
-<BR><VAR>See also <A href=exemple/Example20.html> an example </A> of this method usage in batchmode of %SALOME application.</VAR>
+<BR><VAR>See also <A href="exemple/Example20.html"> an example </A> of this method usage in batchmode of %SALOME application.</VAR>
*/
AttributeStudyProperties GetProperties();
void RemovePostponed(in long theUndoLimit);
void UndoPostponed(in long theWay);
+
+ boolean DumpStudy(in string thePath, in string theBaseName, in boolean isPublished);
+
+/*!
+ Returns an AttributeParameter used to store common parameters for given %theSavePoint.
+ \param theID identifies a common parameters set (Example: "Interface Applicative")
+ \param theSavePoint is number of a set of parameters as there can be several sets
+*/
+ AttributeParameter GetCommonParameters(in string theID, in long theSavePoint);
+
+/*!
+ Returns an AttributeParameter used to store parameters for given %theModuleName.
+ \param theID identifies a common parameters set (Example: "Interface Applicative")
+ \param theModuleName is a name of the module (Example: "Geometry")
+ \param theSavePoint is number of a set of parameters as there can be several sets
+*/
+ AttributeParameter GetModuleParameters(in string theID, in string theModuleName, in long theSavePoint);
+
+
+/*!
+ Returns a default Python script to restore visual parameters for given %theModuleName.
+ \param theID identifies a common parameters set (Example: "Interface Applicative")
+ \param theModuleName is a name of the module (Example: "Geometry")
+*/
+ string GetDefaultScript(in string theID, in string theModuleName);
+
+/*!
+ Private method, returns an implementation of this Study.
+ \param theHostname is a hostname of the caller
+ \param thePID is a process ID of the caller
+ \param isLocal is set True if the Study is launched locally with the caller
+*/
+ long GetLocalImpl(in string theHostname, in long thePID, out boolean isLocal);
+
+
+/*!
+ Marks this Study as being locked by the given locker. The lock status can be checked by method IsStudyLocked
+ \param theLockerID identifies a locker of the study can be for ex. IOR of the engine that locks the study.
+*/
+ void SetStudyLock(in string theLockerID);
+
+/*!
+ Returns True if the Study was marked locked.
+*/
+ boolean IsStudyLocked();
+
+/*!
+ Marks this Study as being unlocked by the given locker. The lock status can be checked by method IsStudyLocked
+ \param theLockerID identifies a locker of the study can be for ex. IOR of the engine that unlocks the study.
+*/
+ void UnLockStudy(in string theLockerID);
+
+/*!
+ Returns the list iof IDs of the Study's lockers.
+*/
+ ListOfStrings GetLockerID();
+
+
};
//==========================================================================
Creates a new %SComponent
\param ComponentDataType Data type of the %SComponent which will be created.
-<BR><VAR>See also <A href=exemple/Example17.html> an example </A> of this method usage in batchmode of %SALOME application.</VAR>
+<BR><VAR>See also <A href="exemple/Example17.html"> an example </A> of this method usage in batchmode of %SALOME application.</VAR>
*/
SComponent NewComponent(in string ComponentDataType) raises(LockProtection);
Defines the instance to the %SComponent.
*/
void DefineComponentInstance (in SComponent aComponent,in Object ComponentIOR) raises(LockProtection);
+
/*! \brief Deletion of a %SComponent
Removes a %SComponent.
\param theFatherObject The father %SObject under which this one should be created.
\return New %SObject
-<BR><VAR>See also <A href=exemple/Example18.html> an example </A> of this method usage in batchmode of %SALOME application.</VAR>
+<BR><VAR>See also <A href="exemple/Example18.html"> an example </A> of this method usage in batchmode of %SALOME application.</VAR>
*/
/*!
Loads a %SComponent.
-<BR><VAR>See also <A href=exemple/Example19.html> an example </A> of this method usage in batchmode of %SALOME application.</VAR>
+<BR><VAR>See also <A href="exemple/Example19.html"> an example </A> of this method usage in batchmode of %SALOME application.</VAR>
*/
void LoadWith (in SComponent sco, in Driver Engine) raises (SALOME::SALOME_Exception);
\param anObject The %SObject corresponding to the attribute which is looked for.
\param aTypeOfAttribute Type of the attribute.
- <BR><VAR>See also <A href=exemple/Example1.html> an example </A> of this method usage in batchmode of %SALOME application.</VAR>
+ <BR><VAR>See also <A href="exemple/Example1.html"> an example </A> of this method usage in batchmode of %SALOME application.</VAR>
*/
GenericAttribute FindOrCreateAttribute(in SObject anObject,
\param anObject The %SObject corresponding to the attribute.
\param aTypeOfAttribute Type of the attribute.
-<BR><VAR>See also <A href=exemple/Example17.html> an example </A> of this method usage in batchmode of %SALOME application.</VAR>
+<BR><VAR>See also <A href="exemple/Example17.html"> an example </A> of this method usage in batchmode of %SALOME application.</VAR>
*/
void RemoveAttribute(in SObject anObject,
in string aTypeOfAttribute) raises(LockProtection);
Adds a directory in the %Study.
\param theName String parameter defining the name of the directory.
-<BR><VAR>See also <A href=exemple/Example23.html> an example </A> of this method usage in batchmode of %SALOME application.</VAR>
+<BR><VAR>See also <A href="exemple/Example23.html"> an example </A> of this method usage in batchmode of %SALOME application.</VAR>
*/
void AddDirectory(in string theName) raises(LockProtection);
Creates a new command which can contain several different actions.
-<BR><VAR>See also <A href=exemple/Example3.html> an example </A> of this method usage in batchmode of %SALOME application.</VAR>
+<BR><VAR>See also <A href="exemple/Example3.html"> an example </A> of this method usage in batchmode of %SALOME application.</VAR>
*/
void NewCommand(); // command management
\exception LockProtection This exception is raised, when trying to perform this command a study, which is protected for modifications.
-<BR><VAR>See also <A href=exemple/Example16.html> an example </A> of this method usage in batchmode of %SALOME application.</VAR>
+<BR><VAR>See also <A href="exemple/Example16.html"> an example </A> of this method usage in batchmode of %SALOME application.</VAR>
*/
void CommitCommand() raises(LockProtection); // command management
Cancels all actions declared within the command.
-<BR><VAR>See also <A href=exemple/Example17.html> an example </A> of this method usage in batchmode of %SALOME application.</VAR>
+<BR><VAR>See also <A href="exemple/Example17.html"> an example </A> of this method usage in batchmode of %SALOME application.</VAR>
*/
void AbortCommand(); // command management
/*! \brief Undolimit
\exception LockProtection This exception is raised, when trying to perform this command a study, which is protected for modifications.
-<BR><VAR>See also <A href=exemple/Example16.html> an example </A> of this method usage in batchmode of %SALOME application.</VAR>
+<BR><VAR>See also <A href="exemple/Example16.html"> an example </A> of this method usage in batchmode of %SALOME application.</VAR>
*/
void Undo() raises (LockProtection);
\exception LockProtection This exception is raised, when trying to perform this command a study, which is protected for modifications.
- <BR><VAR>See also <A href=exemple/Example16.html> an example </A> of this method usage in batchmode of %SALOME application.</VAR>
+ <BR><VAR>See also <A href="exemple/Example16.html"> an example </A> of this method usage in batchmode of %SALOME application.</VAR>
*/
void Redo() raises (LockProtection);
/*!
Returns True if at this moment there are any actions which can be canceled.
- <BR><VAR>See also <A href=exemple/Example16.html> an example </A> of this method usage in batchmode of %SALOME application.</VAR>
+ <BR><VAR>See also <A href="exemple/Example16.html"> an example </A> of this method usage in batchmode of %SALOME application.</VAR>
*/
boolean GetAvailableUndos();
/*!
Returns True if at this moment there are any actions which can be redone.
- <BR><VAR>See also <A href=exemple/Example3.html> an example </A> of this method usage in batchmode of %SALOME application.</VAR>
+ <BR><VAR>See also <A href="exemple/Example3.html"> an example </A> of this method usage in batchmode of %SALOME application.</VAR>
*/
boolean GetAvailableRedos();
-/*!
- This method is called when adding an object into study.
- It sets the callback for addition of the given %SObject.
- \param theCallback New assigned callback.
- \return The previous callback.
-*/
- Callback SetOnAddSObject(in Callback theCallback);
-/*!
- This method is called when adding an object into study.
- It sets the callback for removal of the given %SObject.
-
- \return The previous callback.
- \param theCallback New assigned callback.
-*/
- Callback SetOnRemoveSObject(in Callback theCallback);
-
/*!
Puts name attribute with the given string value to the given %SObject
\param study_name String parameter defining the name of the study
-<BR><VAR>See also <A href=exemple/Example17.html> an example </A> of this method usage in batchmode of %SALOME application.</VAR>
+<BR><VAR>See also <A href="exemple/Example17.html"> an example </A> of this method usage in batchmode of %SALOME application.</VAR>
*/
Study NewStudy(in string study_name);
\param aStudyUrl The path to the study
\warning This method doesn't activate the corba objects. Only a component can do it.
-<BR><VAR>See also <A href=exemple/Example1.html> an example </A> of this method usage in batchmode of %SALOME application.</VAR>
+<BR><VAR>See also <A href="exemple/Example1.html"> an example </A> of this method usage in batchmode of %SALOME application.</VAR>
*/
Study Open (in URL aStudyUrl) raises (SALOME::SALOME_Exception);
\param theMultiFile If this parameter is True the study will be saved in several files.
-<BR><VAR>See also <A href=exemple/Example19.html> an example </A> of this method usage in batchmode of %SALOME application.</VAR>
+<BR><VAR>See also <A href="exemple/Example19.html"> an example </A> of this method usage in batchmode of %SALOME application.</VAR>
*/
- void Save(in Study aStudy, in boolean theMultiFile);
+ boolean Save(in Study aStudy, in boolean theMultiFile);
/*! \brief Saving a study in a ASCII file (or files).
Saves a study in an ASCII format file (or files).
\param theMultiFile If this parameter is True the study will be saved in several files.
*/
- void SaveASCII(in Study aStudy, in boolean theMultiFile);
+ boolean SaveASCII(in Study aStudy, in boolean theMultiFile);
/*! \brief Saving the study in a specified HDF file (or files).
Saves the study in a specified file (or files).
\param aStudy The study which will be saved
\param theMultiFile If this parameter is True the study will be saved in several files.
- <BR><VAR>See also <A href=exemple/Example1.html> an example </A> of this method usage in batchmode of %SALOME application.</VAR>
+ <BR><VAR>See also <A href="exemple/Example1.html"> an example </A> of this method usage in batchmode of %SALOME application.</VAR>
*/
- void SaveAs(in URL aUrl, // if the file already exists
+ boolean SaveAs(in URL aUrl, // if the file already exists
in Study aStudy,
in boolean theMultiFile); // overwrite (as option)
/*! \brief Saving the study in a specified ASCII file (or files).
\param aStudy The study which will be saved
\param theMultiFile If this parameter is True the study will be saved in several files.
*/
- void SaveAsASCII(in URL aUrl, // if the file already exists
+ boolean SaveAsASCII(in URL aUrl, // if the file already exists
in Study aStudy,
in boolean theMultiFile); // overwrite (as option)
an object into a study, which is protected for modifications.
*/
SObject Paste(in SObject theObject) raises (SALOMEDS::StudyBuilder::LockProtection);
+
+/*! \brief Object conversion.
+
+ Converts an object into IOR.
+ \return IOR
+*/
+ string ConvertObjectToIOR(in Object theObject);
+/*! \brief Object conversion.
+
+ Converts IOR into an object.
+ \return An object
+*/
+ Object ConvertIORToObject(in string theIOR);
+
+/*!
+ Private method, returns an implementation of this StudyManager.
+ \param theHostname is a hostname of the caller
+ \param thePID is a process ID of the caller
+ \param isLocal is set True if the StudyManager is launched locally with the caller
+*/
+ long GetLocalImpl(in string theHostname, in long thePID, out boolean isLocal);
+
+
};
*/
//==========================================================================
- interface SObject
+ interface SObject : SALOME::GenericObj
{
/*! Name of the %SObject
*/
\param aTypeOfAttribute String value defining the type of the required attribute of the given %SObject.
\return True if it finds an attribute of a definite type of the given %SObject as well as the discovered attribute.
-<BR><VAR>See also <A href=exemple/Example1.html> an example </A> of this method usage in batchmode of %SALOME application.</VAR>
+<BR><VAR>See also <A href="exemple/Example1.html"> an example </A> of this method usage in batchmode of %SALOME application.</VAR>
*/
boolean FindAttribute(out GenericAttribute anAttribute,
in string aTypeOfAttribute);
\return The list of all attributes of the given %SObject.
-<BR><VAR>See also <A href=exemple/Example17.html> an example </A> of this method usage in batchmode of %SALOME application.</VAR>
+<BR><VAR>See also <A href="exemple/Example17.html"> an example </A> of this method usage in batchmode of %SALOME application.</VAR>
*/
ListOfAttributes GetAllAttributes();
/*! Gets the study of a given %SObject.
- /return The study containing the given %SObject.
+ \return The study containing the given %SObject.
*/
Study GetStudy();
/*! Gets the CORBA object by its own IOR attribute.
Returns nil, if can't.
- /return The CORBA object of the %SObject.
+ \return The CORBA object of the %SObject.
*/
Object GetObject();
Returns empty string if there is no IOR attribute.
*/
string GetIOR();
+
+/*!
+ Private method, returns an implementation of this SObject.
+ \param theHostname is a hostname of the caller
+ \param thePID is a process ID of the caller
+ \param isLocal is set True if the SObject is launched locally with the caller
+*/
+ long GetLocalImpl(in string theHostname, in long thePID, out boolean isLocal);
};
%Generic attribute is a base interface for all attributes which can be assigned to the SObjects created in the study.
*/
//==========================================================================
- interface GenericAttribute
+ interface GenericAttribute : SALOME::GenericObj
{
/*! \brief Exception locking all changes
*/
void CheckLocked() raises (LockProtection);
- string Store();
-
- void Restore(in string theData);
-
string Type();
+ string GetClassType();
+
SObject GetSObject();
+
+/*!
+ Private method, returns an implementation of this GenericAttribute.
+ \param theHostname is a hostname of the caller
+ \param thePID is a process ID of the caller
+ \param isLocal is set True if the GenericAttribute is launched locally with the caller
+*/
+ long GetLocalImpl(in string theHostname, in long thePID, out boolean isLocal);
};
The search is started from the first %SComponent in the list.
*/
//==========================================================================
- interface SComponentIterator
+ interface SComponentIterator : SALOME::GenericObj
{
/*!
Activates the %SComponentIterator.
/*!
Returns the %SComponent corresponding to the current %SComponent found by the iterator.
- <BR><VAR>See also <A href=exemple/Example1.html> an example </A> of this method usage in batchmode of %SALOME application.</VAR>
+ <BR><VAR>See also <A href="exemple/Example1.html"> an example </A> of this method usage in batchmode of %SALOME application.</VAR>
*/
SComponent Value();
levels.
*/
//==========================================================================
- interface ChildIterator
+ interface ChildIterator : SALOME::GenericObj
{
/*!
This interface contains a set of methods used for iteration over the objects in the use case.
*/
- interface UseCaseIterator
+ interface UseCaseIterator : SALOME::GenericObj
{
/*!
Activates the %UseCaseIterator.
Use case in the study represents a user-managed subtree, containing all or some of the objects which exist in the study.
The %UseCaseBuilder interface contains a set of methods used for management of the use case in the study.
*/
- interface UseCaseBuilder
+ interface UseCaseBuilder : SALOME::GenericObj
{
/*!
Adds to the use case an object as a child of the current object of the use case.
UseCaseIterator GetUseCaseIterator(in SObject theObject);
};
//==========================================================================
- //==========================================================================
-/*! \brief The callback interface
-
- The %StudyBuilder can be created with the method <VAR>NewBuilder</VAR>. While invocation of this method a new object of the class <VAR>Callback</VAR> is created
- and this object is assigned to the newly created Builder as callback which should be called when adding and removing of the ojects.
-*/
- interface Callback
- {
-/*!
- Invokes the corresponding method <VAR>Append</VAR> of the %UseCaseBuilder.
-*/
- void OnAddSObject(in SObject theObject);
-/*!
- Invokes the corresponding method <VAR>Remove</VAR> of the %UseCaseBuilder.
-*/
- void OnRemoveSObject(in SObject theObject);
- };
-
- //==========================================================================
/*! \brief %Driver interface
This class represents a common tool for all components integrated into SALOME application, that allows them to communicate with the study. It contains a set of methods which
\param isMultiFile If the value of this boolean parameter is True, the data will be saved in several files.
\return A byte stream TMPFile that contains all saved data
-<BR><VAR>See also <A href=exemple/Example19.html> an example </A> of this method usage in batchmode of %SALOME application.</VAR>
+<BR><VAR>See also <A href="exemple/Example19.html"> an example </A> of this method usage in batchmode of %SALOME application.</VAR>
*/
\param isMultiFile If the value of this boolean parameter is True, the data will be saved in several files.
\return A byte stream TMPFile that will contain all saved data
-<BR><VAR>See also <A href=exemple/Example19.html> an example </A> of this method usage in batchmode of %SALOME application.</VAR>
+<BR><VAR>See also <A href="exemple/Example19.html"> an example </A> of this method usage in batchmode of %SALOME application.</VAR>
*/
TMPFile SaveASCII(in SComponent theComponent, in string theURL, in boolean isMultiFile);