Salome HOME
CCAR: add Observer CORBA object to SALOMEDS module to implement a notification
[modules/kernel.git] / idl / SALOMEDS.idl
1 //  Copyright (C) 2007-2010  CEA/DEN, EDF R&D, OPEN CASCADE
2 //
3 //  Copyright (C) 2003-2007  OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
4 //  CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
5 //
6 //  This library is free software; you can redistribute it and/or
7 //  modify it under the terms of the GNU Lesser General Public
8 //  License as published by the Free Software Foundation; either
9 //  version 2.1 of the License.
10 //
11 //  This library is distributed in the hope that it will be useful,
12 //  but WITHOUT ANY WARRANTY; without even the implied warranty of
13 //  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
14 //  Lesser General Public License for more details.
15 //
16 //  You should have received a copy of the GNU Lesser General Public
17 //  License along with this library; if not, write to the Free Software
18 //  Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307 USA
19 //
20 //  See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
21 //
22
23 //  File   : SALOMEDS.idl
24 //  Author : Yves FRICAUD
25 //  $Header$
26 //
27 /*!  \file SALOMEDS.idl  \brief This file contains a set of interfaces used for creation, management
28   and modification of the %Study
29 */
30
31 #ifndef _SALOMEDS_IDL_
32 #define _SALOMEDS_IDL_
33
34 #include "SALOME_Exception.idl"
35 #include "SALOME_GenericObj.idl"
36
37 /*! \brief
38      This package contains the interfaces used for creation, management
39      and modification of the %Study
40 */
41 module SALOMEDS
42 {
43 /*! \brief Name of the file in which the %Study is saved.
44 */
45   typedef string URL;
46
47 /*! \brief Main identifier of an object in %SALOME application
48 */
49   typedef string ID;
50
51 /*! \brief While saving the data, IOR is transformed into persistent reference
52 */
53   typedef string PersistentReference;
54
55 /*! \brief IOR of the study in %SALOME application
56 */
57   typedef string SalomeReference;
58
59 /*! \brief List of the names of studies which are currently open in this %SALOME session.
60
61 Since %SALOME is a multi-study application, it allows to open a lot of studies
62 during each working session.
63 */
64   typedef sequence<string> ListOfOpenStudies;
65 //! List of file names
66   typedef sequence<string> ListOfFileNames;
67 //! List of modification dates of a study
68   typedef sequence<string> ListOfDates ;
69 //! An unbounded sequence of strings
70   typedef sequence<string> ListOfStrings ;
71 //! An unbounded sequence of sequence of strings
72   typedef sequence<ListOfStrings> ListOfListOfStrings ;
73 //! A byte stream which is used for binary data transfer between different components
74   typedef sequence<octet> TMPFile;
75
76   // Reference to other objects is treated with function AddReference
77   // and ReferencedObject
78   // All other type of attributes defined in AttributeType enum are
79   // treated with AddAdttribute and GetAttribute
80   // The difference is made because Reference attribute don't contain
81   // strings but reference to ID of other objects
82
83   interface GenericAttribute;
84   interface Study;
85   interface StudyManager;
86   interface StudyBuilder;
87   interface SObject;
88   interface SComponent;
89   interface SComponentIterator;
90   interface ChildIterator;
91   interface Driver;
92   interface AttributeStudyProperties;
93   interface AttributeParameter;
94   interface UseCaseIterator;
95   interface UseCaseBuilder;
96
97   interface Observer
98   {
99     void notifyObserverID(in string theID, in long event);
100   };
101
102
103 //! List of attributes of %SObjects
104   typedef sequence<GenericAttribute> ListOfAttributes;
105
106 //! Exception indicating that this feature hasn't been implemented in %SALOME application.
107   exception NotImplemented {};
108
109
110   //===========================================================================
111  /*! \brief %Study Interface
112
113     The purpose of the %Study is to manage the data produced by various components of %SALOME platform.
114    Most of the %Study operations are handled by the StudyManager and the StudyBuilder.
115    What is left in the %Study interface are elementary inquiries.
116    (Incidentally, we recall that a CORBA attribute is implemented as a pair of get
117       and set methods.) A %Study is explored by a set of tools, mainly iterators
118     , which are described further. Nevertheless, the %Study
119      interface allows the search of an object by name or by ID.
120      \note
121      <BR><VAR>The Path </VAR>of an object in %SALOME application is much alike a standard path of a file.
122     In general it's a string of names of directories divided by a slash '/'.
123      <BR><VAR>The Context</VAR> is the current directory of an object.</P>
124 */
125
126   interface Study
127   {
128
129 //! Invalid study context
130     exception StudyInvalidContext {};
131 //! Invalid study component
132     exception StudyInvalidComponent {};
133 //! Invalid directory of the %study exception
134     exception StudyInvalidDirectory {};
135 //! Exception pointing that this name of the study has already been used.
136     exception StudyNameAlreadyUsed {};
137 //! study object already exists
138     exception StudyObjectAlreadyExists {};
139 //! Invalid name of the %study exception
140     exception StudyNameError {};
141 //! Invalid study comment 
142     exception StudyCommentError {};
143
144 /*! \brief The name of the %Study
145
146    This is equivalent to the methods setName() & getName()
147 */
148     attribute string     Name; // equivalent to setName() & getName()
149 /*! \brief The ID of the %Study
150
151    This is equivalent to the methods setID() & getID()
152 */
153     attribute short      StudyId;
154 //! Sequence containing %SObjects
155     typedef sequence<SObject> ListOfSObject;
156 //!  Get the persistent reference to the %Study.
157     PersistentReference  GetPersistentReference();
158 //! Get a transient reference to the %Study.
159     SalomeReference      GetTransientReference();
160
161 /*! \brief indicate whether the %Study is empty
162
163     \return True if the %Study is empty
164 */
165     boolean IsEmpty();
166 /*! \brief  Find a %SComponent by its name.
167
168    \param aComponentName    It's a string value in the Comment Attribute of the Component,
169     which is looked for, defining the data type of this Component.
170
171 <em>See \ref example1 for an example of this method usage in batchmode of %SALOME application.</em>
172
173 */
174     SComponent FindComponent  (in string aComponentName);
175
176 /*! \brief  Find a %SComponent by ID of the according %SObject
177 */
178     SComponent FindComponentID(in ID aComponentID);
179 /*! \brief  Find a %SObject by the Name Attribute of this %SObject
180
181     \param anObjectName String parameter defining the name of the object
182     \return The obtained %SObject
183
184 <em>See \ref example19 for an example of this method usage in batchmode of %SALOME application.</em>
185 */
186     SObject       FindObject      (in string anObjectName);
187 /*! \brief  Find a %SObject by its ID
188
189     \param aObjectID This parameter defines the ID of the required object
190     \return The obtained %SObject
191 */
192     SObject       FindObjectID    (in ID aObjectID);
193 /*! \brief Create a %SObject by its ID
194
195     \param aObjectID This parameter defines the ID of the required object
196     \return The created %SObject
197 */
198     SObject       CreateObjectID    (in ID aObjectID);
199 /*!  \brief Find a %SObject by IOR of the object belonging to this %SObject.
200
201     \param anObjectName This parameter defines the IOR of the object
202     \return The obtained %SObject
203 */
204     SObject       FindObjectIOR   (in ID aObjectIOR);
205 /*! \brief  Find in the study all %SObjects produced by a given %Component.
206
207     \param anObjectName The Name Attribute of the searched %SObjects should correspond to <VAR>anObjectName</VAR>.
208     \param aComponentName The name of the component, which objects are searched for.
209 */
210     ListOfSObject FindObjectByName(in string anObjectName, in string aComponentName);
211 /*! \brief  Find a %SObject by the path to it.
212
213     \param thePath The path to the required %SObject.
214     \return The obtained %SObject.
215 */
216     SObject FindObjectByPath(in string thePath);
217 /*! \brief Get the path to the %SObject.
218 */
219     string  GetObjectPath(in Object theObject);
220
221 /*! \brief  Set the context of the %Study.
222
223     \param thePath String parameter defining the context of the study.
224
225 <em>See \ref example23 for an example of this method usage in batchmode of %SALOME application.</em>
226 */
227     void SetContext(in string thePath);
228 /*!  \brief Get the context of the %Study.
229     
230 <em>See \ref example23 for an example of this method usage in batchmode of %SALOME application.</em>
231 */
232     string GetContext();
233 /*!  \brief Get a list of names of objects corresponding to the context.
234
235    \note  If the parameter <VAR>theContext</VAR> is empty, then the current context will be used.
236 */
237     ListOfStrings GetObjectNames(in string theContext);
238 /*! \brief Get a list of names of directories and subdirectories corresponding to the context.
239
240    \note  If the parameter <VAR>theContext</VAR> is empty, then the current context will be used.
241 */
242     ListOfStrings GetDirectoryNames(in string theContext);
243 /*! \brief  Get a list of names of Files corresponding to the context.
244
245     \note  If the parameter <VAR>theContext</VAR> is empty, then the current context will be used.
246 */
247     ListOfStrings GetFileNames(in string theContext);
248 /*! \brief Get a list of names of Components corresponding to the context.
249
250    \note  If the parameter <VAR>theContext</VAR> is empty, then the current context will be used.
251 */
252     ListOfStrings GetComponentNames(in string theContext);
253 /*!  \brief Create a new iterator of child levels of the given %SObject.
254
255     \param aSO The given %SObject
256     \return A new iterator of child levels of the given %SObject.
257 */
258     ChildIterator      NewChildIterator(in SObject aSO);
259
260 /*!  \brief Create a new iterator of the %SComponents.
261
262     \return A new iterator of the %SComponents.
263 */
264     SComponentIterator NewComponentIterator();
265
266 /*! \brief  Create a new %StudyBuilder to add or modify an object in the study.
267
268    \return A new %StudyBuilder.
269
270 <em>See \ref example20 for an example of this method usage in batchmode of %SALOME application.</em>
271 */
272     StudyBuilder NewBuilder() ;
273 /*! \brief Labels dependency
274
275     Updates the map with IOR attribute. It's an inner method used for optimization.
276 */
277     void UpdateIORLabelMap(in string anIOR, in string anEntry);
278
279 /*! \brief Getting properties of the study
280
281    Returns the attribute, which contains the properties of this study.
282
283 <em>See \ref example20 for an example of this method usage in batchmode of %SALOME application.</em>
284
285 */
286     AttributeStudyProperties GetProperties();
287 /*! \brief  Indicate whether the %study has been saved
288 */
289     attribute boolean IsSaved;
290 /*! \brief  Indicate whether the %study has been modified and not saved.
291
292   Returns True if the %study has been modified and not saved.
293 */
294     boolean IsModified();
295
296 /*! \brief  Mark the %study as being modified and not saved.
297 */
298     void Modified();
299
300 /*! \brief  Indicate the file where the %study has been saved
301 */
302     attribute string  URL;
303
304 /*! \brief List of %SObjects
305
306     Returns the list of %SObjects which refers to %anObject.
307 */
308     ListOfSObject FindDependances(in SObject anObject);
309
310 /*! \brief The date of the last saving of the study
311
312     Returns the date of the last saving of study with format: "DD/MM/YYYY HH:MM"
313 */
314     string GetLastModificationDate();
315 /*! \brief The list of modification dates of the study
316
317     Returns the list of modification dates (without creation date) with format "DD/MM/YYYY HH:MM".
318       Note : the first modification begins the list.
319 */
320     ListOfDates GetModificationsDate();
321 /*! \brief Object conversion.
322
323     Converts an object into IOR.
324     \return    IOR
325 */
326     string ConvertObjectToIOR(in Object theObject);
327 /*! \brief Object conversion.
328
329     Converts IOR into an object.
330     \return    An object
331 */
332     Object ConvertIORToObject(in string theIOR);
333 /*!  \brief Get a new %UseCaseBuilder.
334 */
335     UseCaseBuilder  GetUseCaseBuilder();
336
337 /*! \brief  Close the components in the study, remove itself from the %StudyManager.
338 */
339     void Close();
340
341 /*! \brief  Enable (if isEnabled = True)/disable automatic addition of new %SObjects to the use case.
342 */
343     void EnableUseCaseAutoFilling(in boolean isEnabled);
344
345 /*!
346     Functions for internal usage only
347 */
348     void AddPostponed(in string theIOR);
349
350     void AddCreatedPostponed(in string theIOR);
351
352     void RemovePostponed(in long theUndoLimit);
353
354     void UndoPostponed(in long theWay);
355
356     boolean DumpStudy(in string thePath, in string theBaseName, in boolean isPublished);
357
358 /*! \brief  Get an AttributeParameter used to store common parameters for given %theSavePoint.
359
360     \param theID identifies a common parameters set (Example: "Interface Applicative")
361     \param theSavePoint is number of a set of parameters as there can be several sets
362 */
363     AttributeParameter GetCommonParameters(in string theID, in long theSavePoint);
364
365 /*! \brief  Get an AttributeParameter used to store parameters for given %theModuleName.
366
367     \param theID identifies a common parameters set (Example: "Interface Applicative")
368     \param theModuleName is a name of the module (Example: "Geometry")
369     \param theSavePoint is number of a set of parameters as there can be several sets
370 */
371     AttributeParameter GetModuleParameters(in string theID, in string theModuleName, in long theSavePoint);
372
373
374 /*! \brief Get a default Python script to restore visual parameters for given %theModuleName.
375
376     \param theID identifies a common parameters set (Example: "Interface Applicative")
377     \param theModuleName is a name of the module (Example: "Geometry")
378 */
379     string GetDefaultScript(in string theID, in string theModuleName);
380
381 /*!
382     Private method, returns an implementation of this Study.
383    \param theHostname is a hostname of the caller
384    \param thePID is a process ID of the caller
385    \param isLocal is set True if the Study is launched locally with the caller
386 */
387     long long GetLocalImpl(in string theHostname, in long thePID, out boolean isLocal);
388
389
390 /*! \brief  Mark this Study as being locked by the given locker. 
391
392     The lock status can be checked by method IsStudyLocked
393     \param theLockerID identifies a locker of the study can be for ex. IOR of the engine that locks the study.
394 */
395     void SetStudyLock(in string theLockerID);
396
397 /*! \brief Indicate if the Study is locked
398
399    Returns True if the Study was marked locked. 
400 */
401     boolean IsStudyLocked();
402
403 /*! \brief  Mark this Study as being unlocked by the given locker. 
404
405      The lock status can be checked by method IsStudyLocked
406     \param theLockerID identifies a locker of the study can be for ex. IOR of the engine that unlocks the study.
407 */
408     void UnLockStudy(in string theLockerID);
409
410 /*! \brief  Get the list of IDs of the Study's lockers. 
411 */
412     ListOfStrings GetLockerID();
413
414 /*! \brief  Create real variable with Name theVarName and value theValue 
415
416     (or set if variable value into theValue already exists)
417     \param theVarName is a name of the variable
418     \param theVarName is a value of the variable.
419 */
420     void SetReal( in string theVarName, in double theValue );
421
422 /*! \brief  Create integer variable with Name theVarName and value theValue 
423
424     (or set if variable value into theValue already exists)
425     \param theVarName is a name of the variable
426     \param theVarName is a value of the variable.
427 */
428     void SetInteger( in string theVarName, in long theValue );
429 /*! \brief  Create boolean variable with Name theVarName and value theValue 
430
431     (or set if variable value into theValue already exists)
432     \param theVarName is a name of the variable
433     \param theVarName is a value of the variable.
434 */
435     void SetBoolean( in string theVarName, in boolean theValue );
436
437 /*! \brief  Create string variable with Name theVarName and value theValue 
438
439     (or set if variable value into theValue already exists)
440     \param theVarName is a name of the variable
441     \param theVarName is a value of the variable.
442 */
443     void SetString( in string theVarName, in string theValue );
444
445 /*! \brief  Set current value as double for string variable
446 */
447     void SetStringAsDouble( in string theVarName, in double theValue );
448
449 /*! \brief Get value of a real variable
450
451     \param theVarName is a name of the variable.
452 */
453     double GetReal( in string theVarName );
454
455 /*! \brief Get value of an integer variable
456
457     \param theVarName is a name of the variable.
458 */
459     long GetInteger( in string theVarName );
460
461 /*! \brief Get value of a boolean variable
462
463     \param theVarName is a name of the variable.
464 */
465     boolean GetBoolean( in string theVarName );
466
467 /*! \brief Get value of a string variable
468
469     \param theVarName is a name of the variable.
470 */
471     string GetString( in string theVarName );
472     
473
474 /*! \brief Indicate if a variable is real
475
476     Return true if variable is real otherwise return false.
477     \param theVarName is a name of the variable.
478 */
479     boolean IsReal( in string theVarName );
480
481 /*! \brief Indicate if a variable is integer
482
483     Return true if variable is integer otherwise return false.
484     \param theVarName is a name of the variable.
485 */
486     boolean IsInteger( in string theVarName );
487
488 /*! \brief Indicate if a variable is boolean
489
490     Return true if variable is boolean otherwise return false.
491     \param theVarName is a name of the variable.
492 */
493     boolean IsBoolean( in string theVarName );
494
495 /*! \brief Indicate if a variable is string
496
497     Return true if variable is string otherwise return false.
498     \param theVarName is a name of the variable.
499 */
500     boolean IsString( in string theVarName );
501
502 /*! \brief Indicate if a variable exists in the study
503
504     Return true if variable exists in the study,
505     otherwise return false.
506     \param theVarName is a name of the variable.
507 */
508     boolean IsVariable( in string theVarName );
509
510 /*! \brief Get names of all variables from the study.
511 */
512     ListOfStrings GetVariableNames();
513
514 /*! \brief Remove a variable
515
516    Remove variable with the specified name from the study with substitution of its value.
517
518    \param theVarName Name of the variable.
519    \return Status of operation.
520 */
521     boolean RemoveVariable( in string theVarName );
522
523 /*! \brief Rename a variable
524
525    Rename variable with the specified name within the study.
526
527    \param theVarName Name of the variable.
528    \param theNewVarName New name for the variable.
529    \return Status of operation.
530 */
531     boolean RenameVariable( in string theVarName, in string theNewVarName );
532
533 /*! \brief Indicate whether variable is used
534
535    Check that variable is used in the study.
536
537    \param theVarName Name of the variable.
538    \return Variable usage.
539 */
540     boolean IsVariableUsed( in string theVarName );
541
542 /*! \brief Parse variables used for object creation
543
544    \param string with variables, separated by special symbol. 
545    \return Variables list.
546 */
547     ListOfListOfStrings ParseVariables( in string theVars );
548
549 /*!
550      Attach an observer to the Study
551
552     \param theObserver
553 */
554      void attach(in SALOMEDS::Observer theObserver, in boolean modify);   
555   };
556
557   //==========================================================================
558 /*! \brief %Study Builder Interface
559
560   The purpose of the Builder is to add and/or remove objects and attributes.
561   A %StudyBuilder is linked to a %Study. A
562   command management is provided for the undo/redo functionalities.
563   \note
564   <BR><VAR>The Tag</VAR> of an item in %SALOME application is a symbolic description of
565   item's position in the tree-type structure of the browser. In general it has the following
566   form: <TT>0:2:1:1</TT>
567 */
568   //==========================================================================
569
570   interface StudyBuilder
571   {
572 /*! \brief %LockProtection Exception
573
574     This exception is raised while attempting to modify a locked %study.
575 */
576     exception LockProtection {};
577 /*! \brief Creation of a new %SComponent.
578
579    Creates a new %SComponent
580    \param ComponentDataType    Data type of the %SComponent which will be created.
581
582 <em>See \ref example17 for an example of this method usage in batchmode of %SALOME application.</em>
583
584 */
585     SComponent NewComponent(in string ComponentDataType) raises(LockProtection);
586 /*! \brief Definition of the instance to the %SComponent
587
588     Defines the instance to the %SComponent.
589 */
590     void       DefineComponentInstance (in SComponent aComponent,in Object ComponentIOR) raises(LockProtection);
591         
592 /*! \brief Deletion of a %SComponent
593
594   Removes a %SComponent.
595 */
596     void       RemoveComponent(in SComponent aComponent) raises(LockProtection);
597
598 /*! \brief Creation of a new %SObject
599
600    Creates a new %SObject under a definite father %SObject.
601
602    \param theFatherObject The father %SObject under which this one should be created.
603    \return New %SObject
604
605 <em>See \ref example18 for an example of this method usage in batchmode of %SALOME application.</em>
606
607 */
608
609     SObject NewObject      (in SObject theFatherObject) raises(LockProtection);
610
611 /*! \brief Creation of a new %SObject with a definite %tag
612
613    Creates a new %SObject with a definite %tag.
614
615    \param atag Long value corresponding to the tag of the new %SObject.
616    \return New %SObject
617
618 */
619     SObject NewObjectToTag (in SObject theFatherObject, in long atag) raises(LockProtection);
620 /*! \brief Deletion of the %SObject
621
622   Removes a %SObject from the %StudyBuilder.
623
624   \param anObject The %SObject to be deleted.
625 */
626     void    RemoveObject   (in SObject anObject) raises(LockProtection);
627 /*! \brief Deletion of the %SObject with all his child objects.
628
629   Removes the %SObject with all his child objects.
630
631   \param anObject The %SObject to be deleted with all child objects.
632 */
633     void    RemoveObjectWithChildren(in SObject anObject) raises(LockProtection);
634
635 /*!
636    Loads a %SComponent.
637
638 <em>See \ref example19 for an example of this method usage in batchmode of %SALOME application.</em>
639
640 */
641     void  LoadWith (in SComponent sco, in Driver Engine) raises (SALOME::SALOME_Exception);
642 /*!
643    Loads a %SObject.
644
645    \param sco %SObject to be loaded.
646 */
647     void  Load (in SObject sco);
648
649 /*! \brief Looking for or creating an attribute assigned to the %SObject
650
651     Allows to find or create an attribute of a specific type which is assigned to the object.
652     \param anObject        The %SObject corresponding to the attribute which is looked for.
653     \param aTypeOfAttribute     Type of the attribute.
654
655 <em>See \ref example1 for an example of this method usage in batchmode of %SALOME application.</em>
656 */
657
658     GenericAttribute FindOrCreateAttribute(in  SObject        anObject,
659                                          in  string         aTypeOfAttribute) raises(LockProtection);
660
661 /*! \brief Looking for an attribute assigned to a %SObject
662
663     Allows to find an attribute of a specific type which is assigned to the object.
664     \param anObject        The %SObject corresponding to the attribute which is looked for.
665     \param aTypeOfAttribute     Type of the attribute.
666     \param anAttribute       Where the attribute is placed if it's found.
667     \return True if it finds an attribute.
668  */
669
670     boolean FindAttribute(in  SObject        anObject,
671                                  out GenericAttribute anAttribute,
672                                  in  string         aTypeOfAttribute);
673 /*! \brief Deleting the attribute assigned to the %SObject
674
675     Removes the attribute of a specific type which is assigned to the object.
676     \param anObject        The %SObject corresponding to the attribute.
677     \param aTypeOfAttribute     Type of the attribute.
678
679 <em>See \ref example17 for an example of this method usage in batchmode of %SALOME application.</em>
680 */
681     void RemoveAttribute(in  SObject        anObject,
682                          in  string         aTypeOfAttribute) raises(LockProtection);
683 /*!
684     Adds a reference between %anObject and %theReferencedObject.
685     \param anObject The %SObject which will get a reference
686     \param theReferencedObject The %SObject having a reference
687 */
688
689     void Addreference(in SObject anObject,
690                       in SObject theReferencedObject) ;
691
692 /*!
693     Removes a reference from %anObject to another object.
694     \param anObject The %SObject which contains a reference
695 */
696
697     void RemoveReference(in SObject anObject) ;
698
699 /*!
700    Adds a directory in the %Study.
701    \param theName String parameter defining the name of the directory.
702
703 <em>See \ref example23 for an example of this method usage in batchmode of %SALOME application.</em>
704
705 */
706     void AddDirectory(in string theName) raises(LockProtection);
707
708 /*! \brief Identification of the %SObject's substructure.
709
710       Identification of the %SObject's substructure by GUID.
711
712
713       \param anObject The %SObject which will be identified
714       \param theGUID GUID has the following format "00000000-0000-0000-0000-000000000000"
715 */
716
717      void SetGUID(in SObject anObject, in string theGUID) raises(LockProtection);
718 /*!
719 Searches for a definite %SObject with a definite GUID and returns True if it finds it.
720
721 \param anObject A definite %SObject which will be identified
722 \param theGUID GUID has the following format "00000000-0000-0000-0000-000000000000"
723 */
724      boolean IsGUID(in SObject anObject, in string theGUID);
725
726 /*! \brief Creation of a new command
727
728    Creates a new command which can contain several different actions.
729    
730 <em>See \ref example3 for an example of this method usage in batchmode of %SALOME application.</em>
731
732 */
733     void NewCommand(); // command management
734 /*! \brief Execution of the command
735
736    Commits all actions declared within this command.
737
738    \exception LockProtection This exception is raised, when trying to perform this command a study, which is protected for modifications.
739
740 <em>See \ref example16 for an example of this method usage in batchmode of %SALOME application.</em>
741
742 */
743     void CommitCommand() raises(LockProtection); // command management
744 /*!
745     Returns True if at this moment there is a command under execution.
746 */
747     boolean HasOpenCommand();
748 /*! \brief Cancelation of the command
749
750     Cancels all actions declared within the command.
751     
752 <em>See \ref example17 for an example of this method usage in batchmode of %SALOME application.</em>
753 */
754     void AbortCommand(); // command management
755 /*! \brief Undolimit
756
757     The number of actions which can be undone
758 */
759     attribute long  UndoLimit;
760 /*! \brief Undo method
761
762     Cancels all actions of the last command.
763
764     \exception LockProtection This exception is raised, when trying to perform this command a study, which is protected for modifications.
765
766 <em>See \ref example16 for an example of this method usage in batchmode of %SALOME application.</em>
767
768 */
769     void Undo() raises (LockProtection);
770 /*! \brief Redo method
771
772     Redoes all actions of the last command.
773
774 \exception LockProtection This exception is raised, when trying to perform this command a study, which is protected for modifications.
775
776 <em>See \ref example16 for an example of this method usage in batchmode of %SALOME application.</em>
777
778 */
779     void Redo() raises (LockProtection);
780 /*!
781     Returns True if at this moment there are any actions which can be canceled.
782     
783 <em>See \ref example16 for an example of this method usage in batchmode of %SALOME application.</em>
784
785 */
786     boolean GetAvailableUndos();
787 /*!
788     Returns True if at this moment there are any actions which can be redone.
789
790 <em>See \ref example3 for an example of this method usage in batchmode of %SALOME application.</em>
791
792 */
793     boolean GetAvailableRedos();
794 /*!
795     Puts name attribute with the given string value to the given %SObject
796
797     \param theSO Existing SObject to set name attribute.
798     \param theValue The value to be set to the name attribute.
799 */
800     void SetName(in SObject theSO, in string theValue) raises (LockProtection);
801
802 /*!
803     Puts comment attribute with the given string value to the given %SObject
804
805     \param theSO Existing SObject to set comment attribute.
806     \param theValue The value to be set to the comment attribute.
807 */
808     void SetComment(in SObject theSO, in string theValue) raises (LockProtection);
809
810 /*!
811     Puts IOR attribute with the given string value to the given %SObject
812
813     \param theSO Existing SObject to set IOR attribute.
814     \param theValue The value to be set to the IOR attribute.
815 */
816     void SetIOR(in SObject theSO, in string theValue) raises (LockProtection);
817   };
818
819   //==========================================================================
820 /*! \brief %Study Manager interface
821
822     The purpose of the Manager is to manipulate the %Studies. You will find in this
823     interface the methods to create, open,
824     close, and save a %Study. Since a %SALOME session is multi-document, you will
825     also find the methods allowing to navigate
826     through the collection of studies present in a session.
827 */
828   //==========================================================================
829
830   interface StudyManager
831   {
832 /*!
833     Determines whether the server has already been loaded or not.
834 */
835     void ping();
836
837     void Shutdown();
838
839 /*!
840     Returns the PID of the server
841 */
842     long getPID();
843
844 /*!
845     Shutdown the StudyManager process.
846 */    
847     oneway void ShutdownWithExit();
848
849 /*! \brief Creation of a new study
850
851      Creates a new study with a definite name.
852
853      \param study_name String parameter defining the name of the study
854
855 <em>See \ref example17 for an example of this method usage in batchmode of %SALOME application.</em>
856
857 */
858     Study NewStudy(in string study_name);
859
860 /*! \brief Open a study
861
862      Reads and activates the structure of the study %Objects.
863      \param aStudyUrl The path to the study
864     \warning This method doesn't activate the corba objects. Only a component can do it.
865
866 <em>See \ref example1 for an example of this method usage in batchmode of %SALOME application.</em>
867 */
868     Study Open (in URL aStudyUrl) raises (SALOME::SALOME_Exception);
869
870 /*! \brief Closing the study
871
872     Closes a study.
873 */
874     void  Close(in Study aStudy);
875 /*! \brief Saving the study in a HDF file (or files).
876
877     Saves a study.
878
879     \param theMultiFile If this parameter is True the study will be saved in several files.
880
881 <em>See \ref example19 for an example of this method usage in batchmode of %SALOME application.</em>
882
883 */
884     boolean  Save(in  Study aStudy, in boolean theMultiFile);
885 /*! \brief Saving a study in a ASCII file (or files).
886
887     Saves a study in an ASCII format file (or files).
888     \param theMultiFile If this parameter is True the study will be saved in several files.
889 */
890     boolean  SaveASCII(in  Study aStudy, in boolean theMultiFile);
891 /*! \brief Saving the study in a specified HDF file (or files).
892
893     Saves the study in a specified file (or files).
894     \param aUrl The path to the definite file in whcih the study will be saved
895     \param aStudy The study which will be saved
896     \param theMultiFile If this parameter is True the study will be saved in several files.
897
898 <em>See \ref example1 for an example of this method usage in batchmode of %SALOME application.</em>
899 */
900     boolean  SaveAs(in URL   aUrl, // if the file already exists
901                 in Study aStudy,
902                 in boolean theMultiFile); // overwrite (as option)
903 /*! \brief Saving the study in a specified ASCII file (or files).
904
905     Saves the study in a specified ASCII file (or files).
906
907     \param aUrl The path to the definite file in whcih the study will be saved
908     \param aStudy The study which will be saved
909     \param theMultiFile If this parameter is True the study will be saved in several files.
910 */
911     boolean  SaveAsASCII(in URL   aUrl, // if the file already exists
912                       in Study aStudy,
913                       in boolean theMultiFile); // overwrite (as option)
914
915
916 /*! \brief List of open studies.
917
918 Gets the list of open studies
919
920     \return A list of open studies in the current session.
921 */
922     ListOfOpenStudies GetOpenStudies();
923
924 /*! \brief Getting a particular %Study picked by name
925
926     Activates a particular %Study
927     among the session collection picking it by name.
928     \param aStudyName The name of the study
929 */
930     Study GetStudyByName  (in string aStudyName);
931
932 /*! \brief Getting a particular %Study picked by ID
933
934     Activates a particular %Study
935     among the session collection picking it by ID.
936     \param aStudyID The ID of the study
937 */
938     Study GetStudyByID  (in short aStudyID);
939
940     // copy/paste methods
941
942 /*!
943     Returns True, if the given %SObject can be copied to the clipboard.
944 */
945     boolean CanCopy(in SObject theObject);
946 /*!
947     Returns True, if the given %SObject is copied to the clipboard.
948     \param theObject The %SObject which will be copied
949 */
950     boolean Copy(in SObject theObject);
951 /*!
952     Returns True, if the object from the clipboard can be pasted to the given %SObject.
953     \param theObject The %SObject stored in the clipboard.
954 */
955     boolean CanPaste(in SObject theObject);
956 /*!
957     Returns the %SObject in which the object from the clipboard was pasted to.
958     \param theObject The %SObject which will be pasted
959     \exception SALOMEDS::StudyBuilder::LockProtection This exception is raised, when trying to paste
960     an object into a study, which is protected for modifications.
961 */
962     SObject Paste(in SObject theObject) raises (SALOMEDS::StudyBuilder::LockProtection);
963
964 /*! \brief Object conversion.
965
966     Converts an object into IOR.
967     \return    IOR
968 */
969     string ConvertObjectToIOR(in Object theObject);
970 /*! \brief Object conversion.
971             
972     Converts IOR into an object.
973     \return    An object
974 */
975     Object ConvertIORToObject(in string theIOR); 
976
977 /*!
978     Private method, returns an implementation of this StudyManager.
979    \param theHostname is a hostname of the caller
980    \param thePID is a process ID of the caller
981    \param isLocal is set True if the StudyManager is launched locally with the caller
982 */
983     long long GetLocalImpl(in string theHostname, in long thePID, out boolean isLocal); 
984
985
986   };
987
988
989   //==========================================================================
990 /*! \brief %SObject interface
991
992    The objects in the %study are built by the %StudyBuilder. The %SObject interface
993    provides methods for elementary inquiries, like getting an object %ID or its attribuites.
994  \note
995  
996    <BR><VAR>Tag</VAR> of an item in %SALOME application is an integer value uniquely defining an item
997    in the tree-type data structure.
998    <BR><VAR>ID</VAR> of an item is a description of item's position in the tree-type data structure.
999    ID is a list of tags and it has the following form: <TT>0:2:1:1</TT>.
1000 */
1001   //==========================================================================
1002
1003   interface SObject : SALOME::GenericObj
1004   {
1005 /*! Name of the %SObject
1006 */
1007     attribute string Name; // equivalent to setName() & getName()
1008 /*! Gets an object %ID
1009
1010    \return ID of the %SObject.
1011 */
1012     ID GetID();
1013 /*!  Acquisition of the father %Component of the %SObject
1014
1015   \return The father %Component of the %SObject.
1016 */
1017     SComponent GetFatherComponent();
1018 /*! Acquisition of the father %SObject of the %SObject
1019
1020    \return the father %SObject of the given %SObject.
1021 */
1022     SObject    GetFather();
1023 /*! Gets the %tag of a %SObject
1024
1025     \return the %tag of a %SObject.
1026 */
1027     short      Tag();
1028 /*! Gets the depth of a %SObject
1029
1030     \return the depth of a %SObject.
1031 */
1032     short      Depth();
1033 /*! Looks for subobjects of a given %SObject.
1034
1035     \param atag Tag of the given %SObject
1036     \return True if it finds a subobject of the %SObject with a definite tag as well as the required subobject.
1037 */
1038
1039     boolean FindSubObject (in long atag, out SObject obj);
1040 /*! Looks for attributes of a given %SObject
1041
1042    \param aTypeOfAttribute String value defining the type of the required attribute of the given %SObject.
1043    \return True if it finds an attribute of a definite type of the given %SObject as well as the discovered attribute.
1044
1045 <em>See \ref example1 for an example of this method usage in batchmode of %SALOME application.</em>
1046 */
1047     boolean FindAttribute(out GenericAttribute anAttribute,
1048                                   in  string         aTypeOfAttribute);
1049 /*! Looks for a %SObject which the given %SObject refers to.
1050
1051     \return The object which the given %SObject refers to as well as True if it finds
1052     this object.
1053 */
1054     boolean ReferencedObject(out SObject obj); // A REVOIR
1055 /*! Gets all attributes of a given %SObject
1056
1057     \return The list of all attributes of the given %SObject.
1058
1059 <em>See \ref example17 for an example of this method usage in batchmode of %SALOME application.</em>
1060
1061 */
1062     ListOfAttributes     GetAllAttributes();
1063 /*! Gets the study of a given %SObject.
1064
1065     \return The study containing the given %SObject.
1066 */
1067     Study GetStudy();
1068
1069 /*! Gets the CORBA object by its own IOR attribute.
1070     Returns nil, if can't.
1071
1072     \return The CORBA object of the %SObject.
1073 */
1074     Object GetObject();
1075
1076 /*!
1077     Returns the name attribute value of this SObject.
1078     Returns empty string if there is no name attribute.
1079 */
1080     string GetName();
1081
1082 /*!
1083     Returns the comment attribute value of this SObject.
1084     Returns empty string if there is no comment attribute.
1085 */
1086     string GetComment();
1087
1088 /*!
1089     Returns the IOR attribute value of this SObject.
1090     Returns empty string if there is no IOR attribute.
1091 */
1092     string GetIOR();
1093
1094 /*!
1095     Private method, returns an implementation of this SObject.
1096    \param theHostname is a hostname of the caller
1097    \param thePID is a process ID of the caller
1098    \param isLocal is set True if the SObject is launched locally with the caller
1099 */
1100     long long GetLocalImpl(in string theHostname, in long thePID, out boolean isLocal);
1101   };
1102
1103
1104   //==========================================================================
1105 /*! \brief %Generic attribute interface
1106
1107    %Generic attribute is a base interface for all attributes which can be assigned to the SObjects created in the study.
1108 */
1109   //==========================================================================
1110   interface GenericAttribute : SALOME::GenericObj
1111   {
1112 /*! \brief Exception locking all changes
1113
1114     This exception locks all modifications in attributes.
1115 */
1116     exception LockProtection {};
1117 /*! \brief Method CheckLocked
1118
1119    Checks whether the %Study is protected for modifications.
1120
1121    \note <BR>This exception is raised only outside a transaction.
1122 */
1123     void CheckLocked() raises (LockProtection);
1124
1125     //! Get Type
1126     string Type();
1127
1128     //! Get the class type
1129     string GetClassType();      
1130         
1131     //! Get SObject
1132     SObject GetSObject();
1133
1134   //!  Private method, returns an implementation of this GenericAttribute.
1135 /*!
1136    \param theHostname is a hostname of the caller
1137    \param thePID is a process ID of the caller
1138    \param isLocal is set True if the GenericAttribute is launched locally with the caller
1139 */
1140     long long GetLocalImpl(in string theHostname, in long thePID, out boolean isLocal);
1141   };
1142
1143
1144
1145   //==========================================================================
1146 /*! \brief %SComponent interface
1147
1148    The %SComponent interface establishes in the study a permanent assocition to the Components integrated into %SALOME platform.
1149    The %SComponent interface is a specialization of the %SObject interface.
1150    It inherits the most of its methods from the %SObject interface.
1151 */
1152   //==========================================================================
1153   interface SComponent : SObject
1154   {
1155 /*! \brief Gets the data type of the given %SComponent
1156
1157     \return The data type of this %SComponent.
1158 */
1159     string  ComponentDataType();
1160 /*! \brief Gets the IOR of the given component
1161
1162   \return True (if there is an instance of the given component) and its IOR.
1163 */
1164     boolean ComponentIOR (out ID theID); //returns True if there is an instance
1165                                          //In this case ID identifies this one
1166   };
1167
1168
1169   //==========================================================================
1170 /*! \brief %SComponentIterator interface
1171
1172   This interface contains the methods allowing to iterate over all components in the list.
1173   The search is started from the first %SComponent in the list.
1174 */
1175   //==========================================================================
1176   interface SComponentIterator : SALOME::GenericObj
1177   {
1178 /*!
1179 \brief Activates the %SComponentIterator.
1180 */
1181     void Init();
1182 /*!  \brief Method More
1183
1184    \return True if there is one more %SComponent in the list.
1185 */
1186     boolean More();
1187 /*!
1188 \brief Moves the iterator to the next %SComponent in the list.
1189 */
1190     void Next();
1191 /*!
1192     \brief Returns the %SComponent corresponding to the current %SComponent found by the iterator.
1193
1194 <em>See \ref example1 for an example of this method usage in batchmode of %SALOME application.</em>
1195
1196 */
1197     SComponent Value();
1198   };
1199
1200   //==========================================================================
1201 /*! \brief %ChildIterator interface
1202
1203     This interface contains methods which allow to iterate over all child
1204     levels.
1205 */
1206   //==========================================================================
1207   interface ChildIterator : SALOME::GenericObj
1208   {
1209 /*!
1210
1211 \brief Activates the %ChildIterator.
1212 */
1213     void Init();
1214 /*!
1215
1216 \brief Activates the %ChildIterator for all child levels.
1217
1218 \param allLevels If this boolean parameter is True, the %ChildIterator will be activated for all child levels.
1219 */
1220     void InitEx(in boolean allLevels);
1221 /*! \brief Method More
1222
1223    \return True if there is one more %ChildIterator in the list.
1224 */
1225     boolean More();
1226 /*!
1227     \brief Passes the iterator to the next level.
1228 */
1229     void Next();
1230 /*!
1231     \brief Returns the %SObject corresponding to the current object found by the iterator.
1232 */
1233     SObject Value();
1234   };
1235
1236   //==========================================================================
1237   //==========================================================================
1238 /*! \brief Interface of the %UseCaseIterator.
1239
1240    This interface contains a set of methods used for iteration over the objects in the use case.
1241 */
1242   interface UseCaseIterator : SALOME::GenericObj
1243   {
1244 /*!
1245 Activates the %UseCaseIterator.
1246 \param allLevels If the value of this parameter is True the Iterator is activated for all subobjects.
1247 */
1248     void Init(in boolean allLevels);
1249 /*! Method More
1250
1251     \return True if the %UseCaseIterator finds one more object.
1252 */
1253     boolean More();
1254 /*!
1255     Passes the iterator to the next object.
1256 */
1257     void Next();
1258 /*!
1259     Returns the %SObject corresponding to the current object found by the Iterator.
1260 */
1261     SObject Value();
1262   };
1263
1264   //==========================================================================
1265   //==========================================================================
1266 /*! \brief Interface of the %UseCaseBuilder
1267
1268    Use case in the study represents a user-managed subtree, containing all or some of the objects which exist in the study.
1269    The %UseCaseBuilder interface contains a set of methods used for management of the use case in the study.
1270 */
1271   interface UseCaseBuilder : SALOME::GenericObj
1272   {
1273 /*!
1274    Adds to the use case an object as a child of the current object of the use case.
1275
1276    \param theObject The added %SObject.
1277    \return True if this %SObject has been added in the use case.
1278 */
1279     boolean Append(in SObject theObject);
1280 /*!
1281    Removes an object from the use case.
1282
1283    \param theObject The deleted %SObject
1284    \return True if this %SObject has been deleted from the use case.
1285 */
1286     boolean Remove(in SObject theObject);
1287 /*!
1288    Adds a child object <VAR>theObject</VAR> to the given father <VAR>theFather</VAR> object in the use case.
1289 */
1290     boolean AppendTo(in SObject theFather, in SObject theObject);
1291 /*!
1292     Inserts in the use case the object <VAR>theFirst</VAR> before the object <VAR>theNext</VAR>.
1293 */
1294     boolean InsertBefore(in SObject theFirst, in SObject theNext);
1295 /*!
1296     Sets the current object of the use case.
1297 */
1298     boolean SetCurrentObject(in SObject theObject);
1299 /*!
1300     Makes the root object to be the current object of the use case.
1301 */
1302     boolean SetRootCurrent();
1303 /*!
1304    Returns True if the given object <VAR>theObject</VAR> of the use case has child objects.
1305 */
1306     boolean HasChildren(in SObject theObject);
1307 /*!
1308    Sets the name of the use case.
1309 */
1310     boolean SetName(in string theName);
1311 /*!
1312    Gets the name of the use case.
1313 */
1314     string GetName();
1315 /*!
1316    Returns True if the given object <VAR>theObject</VAR> represents a use case.
1317 */
1318     boolean IsUseCase(in SObject theObject);
1319 /*!
1320     Gets the current object of the use case.
1321 */
1322     SObject GetCurrentObject();
1323 /*!
1324     Creates a new use case in the use case browser.
1325 */
1326     SObject AddUseCase(in string theName);
1327 /*!
1328     Returns the %UseCaseIterator for the given object <VAR>theObject</VAR> in the use case.
1329 */
1330     UseCaseIterator GetUseCaseIterator(in SObject theObject);
1331   };
1332   //==========================================================================
1333 /*! \brief %Driver interface
1334
1335 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
1336 can be called by any component and which provide the following functionality:
1337 <ul>
1338     <li> publishing in the study of the objects created by a definite component
1339     <li> saving/loading of the data created by a definite component. These methods are called by the StudyManager when loading/saving a study containing the data created by a definite component.
1340     <li> transforming of the transient references into persistant references (or vice versa) of the SObjects when saving (or loading) a study
1341     <li> copy/paste common functionality. These methods can be called by any component in order to copy/paste its object created in the study
1342 </ul>
1343
1344 */
1345   //==========================================================================
1346   interface Driver
1347   {
1348
1349     /*! \brief Saving the data produced by a definite component.
1350
1351         This method is called by the StudyManager when saving a study.
1352        \param theComponent    %SComponent corresponding to this Component
1353        \param theURL  The path to the file in which the data will be saved.
1354        \param isMultiFile  If the value of this boolean parameter is True, the data will be saved in several files.
1355        \return A byte stream TMPFile that contains all saved data
1356
1357 <em>See \ref example19 for an example of this method usage in batchmode of %SALOME application.</em>
1358
1359      */
1360
1361
1362     TMPFile Save(in SComponent theComponent, in string theURL, in boolean isMultiFile);
1363
1364 /*! \brief Saving the data in ASCII format produced by a definite component.
1365
1366         This method is called by the StudyManager when saving a study in ASCII format.
1367        \param theComponent    %SComponent corresponding to this Component
1368        \param theURL  The path to the file in which the data will be saved.
1369        \param isMultiFile  If the value of this boolean parameter is True, the data will be saved in several files.
1370        \return A byte stream TMPFile that will contain all saved data
1371
1372 <em>See \ref example19 for an example of this method usage in batchmode of %SALOME application.</em>
1373
1374      */
1375     TMPFile SaveASCII(in SComponent theComponent, in string theURL, in boolean isMultiFile);
1376
1377     /*! \brief Loading the data.
1378
1379        This method is called by the StudyManager when opening a study.
1380        \param theComponent      %SComponent corresponding to this Component
1381        \param theStream   The file which contains all data saved by the component on Save method
1382        \param isMultiFile  If the value of this boolean parameter is True, the data will be loaded from several files
1383
1384      */
1385
1386     boolean Load(in SComponent theComponent, in TMPFile theStream, in string theURL, in boolean isMultiFile);
1387
1388     /*! \brief Loading the data from files in ASCII format.
1389
1390        This method is called by the StudyManager when opening a study.
1391        \param theComponent      %SComponent corresponding to this Component
1392        \param theStream   The file which contains all data saved by the component on Save method
1393        \param isMultiFile  If the value of this boolean parameter is True, the data will be loaded from several files
1394
1395      */
1396
1397     boolean LoadASCII(in SComponent theComponent, in TMPFile theStream, in string theURL, in boolean isMultiFile);
1398
1399     /*! \brief Closing of the study
1400
1401       This method Close is called by the StudyManager when closing a study.
1402     \param aSComponent The according %SComponent
1403      */
1404
1405     void Close (in SComponent aSComponent);
1406     //void Close ( in string  aIORSComponent);
1407
1408     /*! Gets the type of the data
1409
1410         \return The type of data produced by the Component in the study.
1411      */
1412
1413      string ComponentDataType();
1414
1415     // Driver Transient -> persistent called for each object in study
1416 /*!
1417    Transforms IOR of a given %SObject into PersistentID. It is called for each
1418    object in the %study.
1419 \note <br> In %SALOME the objects which are present in an active study are identified by an IOR, when this
1420 study is saved these references are transformed into persintent IDs.
1421
1422    \param theSObject The given %SObject.
1423    \param IORString The IOR of the given %SObject.
1424    \param isMultiFile If this parameter is True the study containing the given %SObject is stored in several files.
1425    \param isASCII If this parameter is True the study containing the given %SObject is stored in ASCII format.
1426
1427    \return The persistent ID of the given %SObject
1428
1429 */
1430     string IORToLocalPersistentID (in SObject theSObject,
1431                                    in string IORString,
1432                                    in boolean isMultiFile,
1433                                    in boolean isASCII);
1434 /*!
1435   Transforms PersistentID into IOR of the object. It is called for each
1436    object in the %study.
1437
1438    \note <br> In %SALOME the objects which are present in an saved study (file) are identified by a persistent ID, when this
1439 study is open, these references are transformed into persintent IORs.
1440
1441    \param theSObject The given %SObject.
1442    \param IORString The IOR of the given %SObject.
1443    \param isMultiFile If this parameter is True the study containing the given %SObject is stored in several files.
1444    \param isASCII If this parameter is True the study containing the given %SObject is stored in ASCII format.
1445
1446    \return The IOR of the given %SObject
1447
1448 */
1449     string LocalPersistentIDToIOR (in SObject theSObject,
1450                                    in string aLocalPersistentID,
1451                                    in boolean isMultiFile,
1452                                    in boolean isASCII)
1453       raises (SALOME::SALOME_Exception);
1454
1455     // Publishing in the study
1456 /*! Publishing in the study
1457
1458     \return True if the given %Component can publish a definite object with a given IOR in the %study.
1459     \param theIOR The IOR of a definite object
1460 */
1461     boolean CanPublishInStudy(in Object theIOR) raises (SALOME::SALOME_Exception);
1462 /*! \brief Publishing in the study
1463
1464    Publishes the given object in the %study, using the algorithm of this component.
1465     \param theStudy     The %study in which the object is published
1466     \param theSObject     If this parameter is null the object is published for the first time. Otherwise
1467     this parameter should contain a reference to the object published earlier
1468     \param theObject      The object which is published
1469     \param theName      The name of the published object. If this parameter is empty, the name is generated
1470     automatically by the component.
1471
1472     \return The published %SObject.
1473 */
1474     SObject PublishInStudy(in Study theStudy, in SObject theSObject, in Object theObject, in string theName);
1475
1476     // copy/paste methods
1477
1478 /*!
1479     Returns True, if the given %SObject can be copied to the clipboard.
1480
1481     \param theObject The given %SObject which should be copied.
1482 */
1483     boolean CanCopy(in SObject theObject);
1484 /*!
1485     Returns the object %ID and the %TMPFile of the object from the given %SObject.
1486 */
1487     TMPFile CopyFrom(in SObject theObject, out long theObjectID);
1488 /*!
1489     Returns True, if the component can paste the object with given %ID of the component with name <VAR>theComponentName</VAR>.
1490 */
1491     boolean CanPaste(in string theComponentName, in long theObjectID);
1492 /*!
1493     Returns the %SObject of the pasted object.
1494 */
1495     SObject PasteInto(in TMPFile theStream, in long theObjectID, in SObject theObject);
1496
1497   };
1498 };
1499
1500 #endif