Go to the documentation of this file.00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024
00025 #ifndef _SALOME_COMPONENT_IDL_
00026 #define _SALOME_COMPONENT_IDL_
00027
00028 #include "SALOME_GenericObj.idl"
00029 #include "SALOMEDS.idl"
00030 #include "SALOME_Exception.idl"
00031 #include "SALOME_PyNode.idl"
00032
00041 module Engines
00042 {
00047 typedef sequence<octet> TMPFile;
00048
00050 struct KeyValuePair
00051 {
00052 string key;
00053 any value;
00054 };
00055
00057 struct dataref
00058 {
00059 string ref;
00060 };
00061
00062 typedef sequence<KeyValuePair> FieldsDict;
00063
00064 interface EngineComponent ;
00065 interface fileRef ;
00066 interface fileTransfer ;
00067 interface Salome_file;
00068
00074 interface Container
00075 {
00076
00085 boolean load_component_Library(in string componentName, out string reason);
00086
00088
00097 Engines::EngineComponent create_component_instance(in string componentName,
00098 in long studyId);
00099
00101
00112 Engines::EngineComponent create_component_instance_env(in string componentName,
00113 in long studyId, in FieldsDict env,
00114 out string reason);
00116
00123 EngineComponent find_component_instance(in string registeredName,
00124 in long studyId);
00125
00127
00136 EngineComponent load_impl(in string nameToRegister,
00137 in string componentName);
00138
00140
00143 void remove_impl(in EngineComponent component_i);
00144
00146 void finalize_removal() ;
00147
00149 void ping();
00150
00152 readonly attribute string name ;
00153
00155 readonly attribute string workingdir ;
00156
00158 attribute string logfilename ;
00159
00161 void Shutdown();
00162
00164 string getHostName();
00165
00167 long getPID();
00168
00170
00175 boolean Kill_impl() ;
00176
00178
00184 fileRef createFileRef(in string origFileName);
00185
00187
00195 Salome_file createSalome_file(in string origFileName);
00196
00198
00203 fileTransfer getFileTransfer();
00204
00206
00211 void copyFile(in Container contai, in string remoteFile, in string localFile);
00212
00214
00218 PyNode createPyNode(in string nodeName, in string code) raises(SALOME::SALOME_Exception);
00219
00221
00225 PyScriptNode createPyScriptNode(in string nodeName, in string code) raises(SALOME::SALOME_Exception);
00226 };
00227
00232 interface EngineComponent
00233 {
00235 readonly attribute string instanceName ;
00236
00238 readonly attribute string interfaceName ;
00239
00241 void ping();
00242
00244
00250 long getStudyId();
00251
00253
00258 void destroy() ;
00259
00261 Container GetContainerRef() ;
00262
00264
00270 void setProperties(in FieldsDict dico);
00271
00273
00277 FieldsDict getProperties();
00278
00280
00286 void Names( in string aGraphName , in string aNodeName ) ;
00287
00289
00292 boolean Kill_impl() ;
00293
00295
00299 boolean Stop_impl() ;
00300
00302
00306 boolean Suspend_impl() ;
00307
00309
00312 boolean Resume_impl() ;
00313
00315
00318 long CpuUsed_impl() ;
00319
00321
00325 TMPFile DumpPython(in Object theStudy,
00326 in boolean isPublished,
00327 in boolean isMultiFile,
00328 out boolean isValidScript);
00329
00330
00332
00342 Engines::Salome_file getInputFileToService(in string service_name,
00343 in string Salome_file_name) raises(SALOME::SALOME_Exception);
00344
00346
00361 void checkInputFilesToService(in string service_name) raises(SALOME::SALOME_Exception);
00362
00364
00374 Engines::Salome_file setInputFileToService(in string service_name,
00375 in string Salome_file_name) raises(SALOME::SALOME_Exception);
00376
00378
00388 Engines::Salome_file getOutputFileToService(in string service_name,
00389 in string Salome_file_name) raises(SALOME::SALOME_Exception);
00390
00392
00407 void checkOutputFilesToService(in string service_name) raises(SALOME::SALOME_Exception);
00408
00410
00420 Engines::Salome_file setOutputFileToService(in string service_name,
00421 in string Salome_file_name) raises(SALOME::SALOME_Exception);
00422
00424
00429 boolean hasObjectInfo();
00430
00432
00443 string getObjectInfo(in long studyId, in string entry);
00444 } ;
00445
00449 interface ImportableComponent
00450 {
00452 SALOME::StringSeq GetImportableFormats();
00453 boolean ImportDataAs(in string format, in SALOME::GenericObj exporter);
00454 };
00455
00457 typedef sequence<octet> fileBlock;
00458
00463 interface fileTransfer : SALOME::GenericObj
00464 {
00466
00474 long open(in string fileName);
00476
00480 long openW(in string fileName);
00481
00483
00487 void close(in long fileId);
00488
00490
00494 fileBlock getBlock(in long fileId);
00495
00497
00501 void putBlock(in long fileId, in fileBlock block);
00502
00503 };
00504
00506 struct file {
00508 string file_name;
00510 string path;
00511 string type;
00512 string source_file_name;
00514 string status;
00515 long node;
00516 Engines::Container container;
00517 };
00518
00520 typedef sequence<Engines::file> files;
00521
00522
00524 struct SfState {
00526 string name;
00528 string hdf5_file_name;
00530 long number_of_files;
00532 boolean files_ok;
00533
00534 };
00535
00541 interface Salome_file : Engines::fileTransfer
00542 {
00544
00550 void load(in string hdf5_file) raises (SALOME::SALOME_Exception);
00551
00553
00560 void save(in string hdf5_file) raises (SALOME::SALOME_Exception);
00561
00563
00571 void save_all(in string hdf5_file) raises (SALOME::SALOME_Exception);
00572
00573
00574
00576
00582 void setLocalFile(in string comp_file_name) raises (SALOME::SALOME_Exception);
00583
00585
00591 void setDistributedFile(in string comp_file_name) raises (SALOME::SALOME_Exception);
00592
00594
00601 void connect(in Engines::Salome_file source_Salome_file) raises (SALOME::SALOME_Exception);
00602
00604
00611 void connectDistributedFile(in string file_name,
00612 in Engines::Salome_file source_Salome_file) raises (SALOME::SALOME_Exception);
00613
00615
00622 void setDistributedSourceFile(in string file_name,
00623 in string source_file_name) raises (SALOME::SALOME_Exception);
00624
00625
00626
00628
00632 void recvFiles() raises (SALOME::SALOME_Exception) ;
00633
00634
00635
00637
00643 void removeFile(in string file_name) raises (SALOME::SALOME_Exception);
00644
00646 void removeFiles();
00647
00648
00649
00651
00654 Engines::files getFilesInfos();
00655
00657
00665 Engines::file getFileInfos(in string file_name) raises (SALOME::SALOME_Exception);
00666
00668 Engines::SfState getSalome_fileState();
00669
00670
00672
00676 void setContainer(in Engines::Container container);
00677 };
00678
00696 interface fileRef
00697 {
00699 readonly attribute string origFileName;
00701 readonly attribute string refMachine;
00702
00703 Container getContainer();
00704
00705 boolean addRef(in string machine,
00706 in string fileName);
00707
00708 string getRef(in string machine);
00709 };
00710 };
00711
00712 #endif