00001
00010 #ifndef EDG_WORKLOAD_COMMON_CONFIGURATION_JCCONFIGURATION_H
00011 #define EDG_WORKLOAD_COMMON_CONFIGURATION_JCCONFIGURATION_H
00012
00013 #include "confbase.h"
00014
00015 COMMON_NAMESPACE_BEGIN {
00016
00017 namespace configuration {
00018
00019 class JCConfiguration : public confbase_c {
00020 public:
00021 JCConfiguration( const classad::ClassAd *ad );
00022
00023 ~JCConfiguration( void );
00024
00025
00026 inline bool use_fake_for_proxy( bool def = false ) const
00027 {
00028 return this->getBool( "UseFakeForProxy", def );
00029 }
00030
00031 inline bool use_fake_for_real( bool def = false ) const
00032 {
00033 return this->getBool( "UseFakeForReal", def );
00034 }
00035
00036 inline int container_refresh_threshold( int def = 1000 ) const
00037 {
00038 return this->getInt( "ContainerRefreshThreshold", def );
00039 }
00040
00041 inline std::string condor_submit( const std::string &def = "" ) const
00042 {
00043 return this->getAndParseFileName( "CondorSubmit", def );
00044 }
00045
00046 inline std::string condor_remove( const std::string &def = "" ) const
00047 {
00048 return this->getAndParseFileName( "CondorRemove", def );
00049 }
00050
00051 inline std::string condor_query( const std::string &def = "" ) const
00052 {
00053 return this->getAndParseFileName( "CondorQuery", def );
00054 }
00055
00056 inline std::string condor_submit_dag( const std::string &def = "" ) const
00057 {
00058 return this->getAndParseFileName( "CondorSubmitDag", def );
00059 }
00060
00061 inline std::string condor_release( const std::string &def = "" ) const
00062 {
00063 return this->getAndParseFileName( "CondorRelease", def );
00064 }
00065
00066 inline std::string input( const std::string &def = "" ) const
00067 {
00068 return this->getAndParseFileName( "Input", def );
00069 }
00070
00071 inline std::string submit_file_dir( const std::string &def = "" ) const
00072 {
00073 return this->getAndParseFileName( "SubmitFileDir", def );
00074 }
00075
00076 inline std::string output_file_dir( const std::string &def = "" ) const
00077 {
00078 return this->getAndParseFileName( "OutputFileDir", def );
00079 }
00080
00081 inline int max_concurrent_condor_commands( int def = 10 ) const
00082 {
00083 return this->getInt( "MaxConcurrentCondorCommands", def );
00084 }
00085
00086 inline std::string log_file( const std::string &def = "" ) const
00087 {
00088 return this->getAndParseFileName( "LogFile", def );
00089 }
00090
00091 inline std::string log_rotation_base_file( const std::string &def = "[[LogFile]]" ) const
00092 {
00093 return this->getAndParseFileName( "LogRotationBaseFile", def );
00094 }
00095
00096 inline std::string lock_file( const std::string &def = "" ) const
00097 {
00098 return this->getAndParseFileName( "LockFile", def );
00099 }
00100
00101 inline int log_level( int def = 0 ) const
00102 {
00103 return this->getInt( "LogLevel", def );
00104 }
00105
00106 inline unsigned int log_rotation_max_file_number( unsigned int def = 5 ) const
00107 {
00108 return static_cast<unsigned int>( this->getInt( "LogRotationMaxFileNumber", def ) );
00109 }
00110
00111 inline std::streamsize log_file_max_size( std::streamsize def = 100000000 ) const
00112 {
00113 return static_cast<std::streamsize>( this->getInt( "LogFileMaxSize", def ) );
00114 }
00115
00116 };
00117
00118 };
00119
00120 } COMMON_NAMESPACE_END;
00121
00122 #endif
00123
00124
00125
00126