コード例 #1
0
 def configure(self, config):
     Formatter.configure(self, config)
     set_attribute(self,'data_delimiter', ',', config)
     set_attribute(self,'header_delimiter', self.data_delimiter, config, str)
     set_attribute(self,'prefix', '', config)
     set_attribute(self,'suffix', '', config)
     set_attribute(self, 'timestamp_format', '%Y-%m-%dT%H:%M:%S', config)
コード例 #2
0
 def configure(self, config):
     Formatter.configure(self, config)
     set_attribute(self, 'data_delimiter', ',', config)
     set_attribute(self, 'header_delimiter', self.data_delimiter, config,
                   str)
     set_attribute(self, 'prefix', '', config)
     set_attribute(self, 'suffix', '', config)
     set_attribute(self, 'timestamp_format', '%Y-%m-%dT%H:%M:%S', config)
コード例 #3
0
 def configure(self, config):
     Formatter.configure(self, config)
     self.period = self.parent.log.period
     set_attribute(self, 'sender_id', 'Envenergy', config)
     set_attribute(self, 'customer_id', '', config)
     set_attribute(self, 'receiver_id', 'Enerwise', config)
     set_attribute(self, 'commodity', 'E', config)
     set_attribute(self, 'timestamp_format', '%Y%m%d%H%M', config)
     set_attribute(self, 'max_count', 48, config, int)
コード例 #4
0
 def configure(self, config):
     Formatter.configure(self, config)
     self.period = self.parent.log.period
     set_attribute(self, "sender_id", "Envenergy", config)
     set_attribute(self, "customer_id", "", config)
     set_attribute(self, "receiver_id", "Enerwise", config)
     set_attribute(self, "commodity", "E", config)
     set_attribute(self, "timestamp_format", "%Y%m%d%H%M", config)
     set_attribute(self, "max_count", 48, config, int)
コード例 #5
0
 def configure(self, config):
     Formatter.configure(self, config)
     set_attribute(self, 'debug_lvl', 0, config, int)
     set_attribute(self, 'timestamp_format', '%Y-%m-%dT%H:%M:%S', config)
     set_attribute(self, 'pretty_format',0,config,as_boolean)
     set_attribute(self, 'location_info','DefaultLocationInfo',config)
     set_attribute(self, 'location_key','DefaultLocationKey',config)
     set_attribute(self, 'panel_info','DefaultPanelInfo',config)
     set_attribute(self, 'panel_key','DefaultPanelKey',config)
     set_attribute(self, 'capture_period',24.0,config,float) # capture period preceding data transmission time (hrs)
     set_attribute(self, 'exception_log_url','/services/logger/fsg_exception_log',config)
コード例 #6
0
ファイル: ewebconnect.py プロジェクト: ed-aicradle/monotone
 def configure(self, config):
     Formatter.configure(self, config)
     set_attribute(self, 'line_one', '"ACDIAG"\n', config)
     set_attribute(self, 'line_two', '"Diagnostics"\n', config)
     set_attribute(self, 'line_three', '"Average"\n\n\n', config)
     set_attribute(self, 'line_four', 'begindata\n', config)
     set_attribute(self, 'line_five', '', config)
     set_attribute(self, 'line_six', '', config)
     set_attribute(self, 'line_seven', '', config)
     set_attribute(self, 'line_eight', '', config)
     set_attribute(self, 'line_nine', '', config)
     set_attribute(self, 'line_ten', '', config)
     set_attribute(self, 'date_format', '"%m/%d/%y"', config)
     set_attribute(self, 'time_format', '"%H:%M:%S"', config)
     set_attribute(self, 'value_format', '"%14.3f"', config)
     set_attribute(self, 'max_value_length', 16, config, int)
コード例 #7
0
ファイル: ewebconnect.py プロジェクト: mcruse/monotone
 def configure(self, config):
     Formatter.configure(self, config)
     set_attribute(self,'line_one', '"ACDIAG"\n', config)
     set_attribute(self,'line_two', '"Diagnostics"\n', config)
     set_attribute(self,'line_three', '"Average"\n\n\n', config)
     set_attribute(self,'line_four', 'begindata\n', config)
     set_attribute(self,'line_five', '', config)
     set_attribute(self,'line_six', '', config)
     set_attribute(self,'line_seven', '', config)
     set_attribute(self,'line_eight', '', config)
     set_attribute(self,'line_nine', '', config)
     set_attribute(self,'line_ten', '', config)
     set_attribute(self,'date_format', '"%m/%d/%y"', config)
     set_attribute(self,'time_format', '"%H:%M:%S"', config) 
     set_attribute(self,'value_format', '"%14.3f"', config) 
     set_attribute(self,'max_value_length', 16, config, int)
コード例 #8
0
ファイル: infotility.py プロジェクト: ed-aicradle/monotone
 def configure(self, config):
     Formatter.configure(self, config)
     set_attribute(self, 'timestamp_format', '%m/%d/%Y %I:%M:%S %p', config)
     set_attribute(self, 'info', '', config)
     set_attribute(self, 'pretty_format',0,config,as_boolean)
     set_attribute(self, 'prefix', 'do_method=notify&cdvalues=', config)
     set_attribute(self, 'suffix', '', config)
     set_attribute(self, 'station_code', '4', config)
     set_attribute(self, 'time_base', REQUIRED, config)
     set_attribute(self, 'status1', '', config)
     set_attribute(self, 'status2', '', config)
     set_attribute(self, 'status3', '', config)
     set_attribute(self, 'status4', '', config)
     set_attribute(self, 'status5', '', config)
     set_attribute(self, 'status6', '', config)
     set_attribute(self, 'status7', '', config)
     set_attribute(self, 'status8', '', config)
コード例 #9
0
 def configure(self, config):
     Formatter.configure(self, config)
     set_attribute(self, 'prefix', '', config)
     set_attribute(self, 'suffix', '', config)
     return
コード例 #10
0
ファイル: power_web.py プロジェクト: mcruse/monotone
 def configure(self, config):
     Formatter.configure(self, config)
     set_attribute(self, 'timestamp_format', '%Y/%m/%d %H:%M:%S', config)
コード例 #11
0
    def configure(self, config):
        Formatter.configure(self, config)
        #
        # Usually hardcoded/calculated at runtime.
        #
        set_attribute(self, 'generated_by', '', config, stripped_str)
        if not self.generated_by:
            self.generated_by = 'Mediator MMA File v1.x'
        set_attribute(self, 'generated_by_namespace', '', config, stripped_str)
        if not self.generated_by_namespace:
            self.generated_by_namespace = 'Mediator Generated File'
        set_attribute(self, 'device_namespace', '', config, stripped_str)
        if not self.device_namespace:
            self.device_namespace = 'IONEnterprise'
        set_attribute(self, 'device_type', '', config, stripped_str)
        if not self.device_type:
            self.device_type = 'presumed downstream device'
# Not required according to Stephan Jones
#         set_attribute(self, 'timezone_bias', '', config, stripped_str)
#         if not self.timezone_bias:
#             self.timezone_bias = mma_timezone.bias_text()
#         set_attribute(self, 'timezone_dst_bias', '', config, stripped_str)
#         if not self.timezone_dst_bias:
#             self.timezone_dst_bias = mma_timezone.dst_bias_text()
#         set_attribute(self, 'timezone_dst_start', '', config, stripped_str)
#         if not self.timezone_dst_start:
#             self.timezone_dst_start = mma_timezone.dst_start_text()
#         set_attribute(self, 'timezone_dst_end', '', config, str)
#         if not self.timezone_dst_end:
#             self.timezone_dst_end = mma_timezone.dst_end_text()
# Now programmatically calculated:
#         set_attribute(self, 'device_timezone_bias', '', config, stripped_str)
#         if not self.device_timezone_bias:
#             self.device_timezone_bias = mma_timezone.bias_text()
#         set_attribute(self, 'device_timezone_dst_bias', '',
#                       config, stripped_str)
#         if not self.device_timezone_dst_bias:
#             self.device_timezone_dst_bias = mma_timezone.dst_bias_text()
#         set_attribute(self, 'device_timezone_dst_start', '',
#                       config, stripped_str)
#         if not self.device_timezone_dst_start:
#             self.device_timezone_dst_start = mma_timezone.dst_start_text()
#         set_attribute(self, 'device_timezone_dst_end', '', config, str)
#         if not self.device_timezone_dst_end:
#             self.device_timezone_dst_end = mma_timezone.dst_end_text()
        #
        # Optional
        #
        set_attribute(self, 'generated_by_type', '', config, stripped_str)
        set_attribute(self, 'generated_by_signature', '', config, stripped_str)
        set_attribute(self, 'device_signature', '', config, str)
        set_attribute(self, 'device_configuration_template', '', config, str)
        set_attribute(self, 'device_configuration_owner', '', config, str)
        set_attribute(self, 'device_configuration_tag1', '', config, str)
        set_attribute(self, 'device_configuration_tag2', '', config, str)
        set_attribute(self, 'device_configuration_revision', '', config, str)
        set_attribute(self, 'data_recorder_handle', '', config, str)
        set_attribute(self, 'add_smtp_envelope', '1', config, int)
        
# Not required according to Stephan Jones
#         set_attribute(self, 'configuration_template', 'none', config, str)
#         set_attribute(self, 'configuration_owner', 'unknown', config, str)
#         set_attribute(self, 'configuration_tag1', 'n/a', config, str)
#         set_attribute(self, 'configuration_tag2', 'n/a', config, str)
#         set_attribute(self, 'configuration_revision', '2.0', config, str)
        #
        # REQUIRED
        #
        set_attribute(self, 'device_name', REQUIRED, config, str)
        set_attribute(self, 'data_recorder_id', REQUIRED, config, str)
        set_attribute(self, 'data_recorder_label', REQUIRED, config, str)
        return
コード例 #12
0
 def configure(self, config):
     Formatter.configure(self, config)
     self.period = self.parent.parent.parent.period
     set_attribute(self, 'customer_name', REQUIRED, config)
     set_attribute(self, 'account_name', REQUIRED, config)
     set_attribute(self, 'commodity', 'E', config)
コード例 #13
0
 def configure(self, config):
     Formatter.configure(self, config)
     set_attribute(self, 'timestamp_format', '%Y-%m-%dT%H:%M:%S', config)
     set_attribute(self, 'info', '', config)
     set_attribute(self, 'pretty_format', 0, config, as_boolean)
コード例 #14
0
 def configure(self, config):
     Formatter.configure(self, config)
     set_attribute(self, "prefix", "", config)
     set_attribute(self, "suffix", "", config)
     return
コード例 #15
0
ファイル: xml_formatter.py プロジェクト: mcruse/monotone
 def configure(self, config):
     Formatter.configure(self, config)
     set_attribute(self, 'timestamp_format', '%Y-%m-%dT%H:%M:%S', config)
     set_attribute(self, 'info', '', config)
     set_attribute(self, 'pretty_format',0,config,as_boolean)
コード例 #16
0
ファイル: cmep_formatter.py プロジェクト: mcruse/monotone
 def configure(self, config):
     Formatter.configure(self, config)
     self.period = self.parent.parent.parent.period
     set_attribute(self, 'customer_name', REQUIRED, config)
     set_attribute(self, 'account_name', REQUIRED, config)
     set_attribute(self, 'commodity', 'E', config)
コード例 #17
0
 def configure(self, config):
     Formatter.configure(self, config)
     set_attribute(self, 'timestamp_format', '%Y-%m-%dT%H:%M:%S', config)