<s> from django . core . urlresolvers import reverse <EOL> from django . utils . translation import ugettext_lazy as _ <EOL> from horizon import tables <EOL> class AddAppPolicyLink ( tables . LinkAction ) : <EOL> name = "<STR_LIT>" <EOL> verbose_name = _ ( "<STR_LIT>" ) <EOL> url = "<STR_LIT>" <EOL> classes = ( "<STR_LIT>" , "<STR_LIT>" , ) <EOL> class UpdateAppPolicyLink ( tables . LinkAction ) : <EOL> name = "<STR_LIT>" <EOL> verbose_name = _ ( "<STR_LIT>" ) <EOL> classes = ( "<STR_LIT>" , '<STR_LIT>' ) <EOL> def get_link_url ( self , policy_rule_set ) : <EOL> urlpath = "<STR_LIT>" <EOL> base_url = reverse ( urlpath , kwargs = { <EOL> '<STR_LIT>' : policy_rule_set . id } ) <EOL> return base_url <EOL> class DeleteAppPolicyLink ( tables . DeleteAction ) : <EOL> name = "<STR_LIT>" <EOL> action_present = _ ( "<STR_LIT>" ) <EOL> action_past = _ ( "<STR_LIT>" ) <EOL> data_type_singular = _ ( "<STR_LIT>" ) <EOL> data_type_plural = _ ( "<STR_LIT>" ) <EOL> class AddPolicyRuleLink ( tables . LinkAction ) : <EOL> name = "<STR_LIT>" <EOL> verbose_name = _ ( "<STR_LIT>" ) <EOL> url = "<STR_LIT>" <EOL> classes = ( "<STR_LIT>" , "<STR_LIT>" , ) <EOL> class UpdatePolicyRuleLink ( tables . LinkAction ) : <EOL> name = "<STR_LIT>" <EOL> verbose_name = _ ( "<STR_LIT>" ) <EOL> classes = ( "<STR_LIT>" , "<STR_LIT>" , ) <EOL> def get_link_url ( self , policy_rule ) : <EOL> urlstring = "<STR_LIT>" <EOL> base_url = reverse ( urlstring , <EOL> kwargs = { '<STR_LIT>' : policy_rule . id } ) <EOL> return base_url <EOL> class DeletePolicyRuleLink ( tables . DeleteAction ) : <EOL> name = "<STR_LIT>" <EOL> action_present = _ ( "<STR_LIT>" ) <EOL> action_past = _ ( "<STR_LIT>" ) <EOL> data_type_singular = _ ( "<STR_LIT>" ) <EOL> data_type_plural = _ ( "<STR_LIT>" ) <EOL> class AddPolicyClassifierLink ( tables . LinkAction ) : <EOL> name = "<STR_LIT>" <EOL> verbose_name = _ ( "<STR_LIT>" ) <EOL> url = "<STR_LIT>" <EOL> classes = ( "<STR_LIT>" , "<STR_LIT>" , ) <EOL> class UpdatePolicyClassifierLink ( tables . LinkAction ) : <EOL> name = "<STR_LIT>" <EOL> verbose_name = _ ( "<STR_LIT>" ) <EOL> classes = ( "<STR_LIT>" , "<STR_LIT>" , ) <EOL> def get_link_url ( self , policy_classifier ) : <EOL> base_url = reverse ( <EOL> "<STR_LIT>" , <EOL> kwargs = { '<STR_LIT>' : policy_classifier . id } ) <EOL> return base_url <EOL> class DeletePolicyClassifierLink ( tables . DeleteAction ) : <EOL> name = "<STR_LIT>" <EOL> action_present = _ ( "<STR_LIT>" ) <EOL> action_past = _ ( "<STR_LIT>" ) <EOL> data_type_singular = _ ( "<STR_LIT>" ) <EOL> data_type_plural = _ ( "<STR_LIT>" ) <EOL> class AddPolicyActionLink ( tables . LinkAction ) : <EOL> name = "<STR_LIT>" <EOL> verbose_name = _ ( "<STR_LIT>" ) <EOL> url = "<STR_LIT>" <EOL> classes = ( "<STR_LIT>" , "<STR_LIT>" , ) <EOL> class UpdatePolicyActionLink ( tables . LinkAction ) : <EOL> name = "<STR_LIT>" <EOL> verbose_name = _ ( "<STR_LIT>" ) <EOL> classes = ( "<STR_LIT>" , "<STR_LIT>" , ) <EOL> def get_link_url ( self , policy_action ) : <EOL> urlstring = "<STR_LIT>" <EOL> base_url = reverse ( urlstring , <EOL> kwargs = { '<STR_LIT>' : policy_action . id } ) <EOL> return base_url <EOL> class DeletePolicyActionLink ( tables . DeleteAction ) : <EOL> name = "<STR_LIT>" <EOL> action_present = _ ( "<STR_LIT>" ) <EOL> action_past = _ ( "<STR_LIT>" ) <EOL> data_type_singular = _ ( "<STR_LIT>" ) <EOL> data_type_plural = _ ( "<STR_LIT>" ) <EOL> class ApplicationPoliciesTable ( tables . DataTable ) : <EOL> name = tables . Column ( "<STR_LIT:name>" , <EOL> verbose_name = _ ( "<STR_LIT:Name>" ) , <EOL> link = "<STR_LIT>" ) <EOL> description = tables . Column ( "<STR_LIT:description>" , <EOL> verbose_name = _ ( "<STR_LIT>" ) ) <EOL> policy_rules = tables . Column ( "<STR_LIT>" , <EOL> sortable = False , <EOL> verbose_name = _ ( "<STR_LIT>" ) ) <EOL> class Meta ( object ) : <EOL> name = "<STR_LIT>" <EOL> verbose_name = _ ( "<STR_LIT>" ) <EOL> table_actions = ( AddAppPolicyLink , DeleteAppPolicyLink ) <EOL> row_actions = ( UpdateAppPolicyLink , DeleteAppPolicyLink ) <EOL> class PolicyRulesTable ( tables . DataTable ) : <EOL> name = tables . Column ( "<STR_LIT:name>" , <EOL> verbose_name = _ ( "<STR_LIT:Name>" ) , <EOL> link = "<STR_LIT>" ) <EOL> description = tables . Column ( "<STR_LIT:description>" , <EOL> verbose_name = _ ( "<STR_LIT>" ) ) <EOL> enabled = tables . Column ( "<STR_LIT>" , <EOL> verbose_name = _ ( "<STR_LIT>" ) ) <EOL> policy_classifier = tables . Column ( "<STR_LIT>" , <EOL> verbose_name = _ ( "<STR_LIT>" ) ) <EOL> policy_actions = tables . Column ( "<STR_LIT>" , <EOL> verbose_name = _ ( "<STR_LIT>" ) ) <EOL> class Meta ( object ) : <EOL> name = "<STR_LIT>" <EOL> verbose_name = _ ( "<STR_LIT>" ) <EOL> table_actions = ( AddPolicyRuleLink , DeletePolicyRuleLink ) <EOL> row_actions = ( UpdatePolicyRuleLink , DeletePolicyRuleLink ) <EOL> class PolicyClassifiersTable ( tables . DataTable ) : <EOL> name = tables . Column ( "<STR_LIT:name>" , <EOL> verbose_name = _ ( "<STR_LIT:Name>" ) , <EOL> link = "<STR_LIT>" ) <EOL> description = tables . Column ( "<STR_LIT:description>" , <EOL> verbose_name = _ ( "<STR_LIT>" ) ) <EOL> protocol = tables . Column ( "<STR_LIT>" , <EOL> verbose_name = _ ( "<STR_LIT>" ) ) <EOL> port_range = tables . Column ( "<STR_LIT>" , <EOL> verbose_name = _ ( "<STR_LIT>" ) ) <EOL> direction = tables . Column ( "<STR_LIT>" , <EOL> verbose_name = _ ( "<STR_LIT>" ) ) <EOL> class Meta ( object ) : <EOL> name = "<STR_LIT>" <EOL> verbose_name = _ ( "<STR_LIT>" ) <EOL> table_actions = ( AddPolicyClassifierLink , DeletePolicyClassifierLink ) <EOL> row_actions = ( UpdatePolicyClassifierLink , DeletePolicyClassifierLink ) <EOL> class PolicyActionsTable ( tables . DataTable ) : <EOL> name = tables . Column ( "<STR_LIT:name>" , <EOL> verbose_name = _ ( "<STR_LIT:Name>" ) , <EOL> link = "<STR_LIT>" ) <EOL> description = tables . Column ( "<STR_LIT:description>" , <EOL> verbose_name = _ ( "<STR_LIT>" ) ) <EOL> action_type = tables . Column ( "<STR_LIT>" , <EOL> verbose_name = _ ( "<STR_LIT>" ) ) <EOL> action_value = tables . Column ( "<STR_LIT>" , <EOL> verbose_name = _ ( "<STR_LIT>" ) ) <EOL> class Meta ( object ) : <EOL> name = "<STR_LIT>" <EOL> verbose_name = _ ( "<STR_LIT>" ) <EOL> table_actions = ( AddPolicyActionLink , DeletePolicyActionLink ) <EOL> row_actions = ( UpdatePolicyActionLink , DeletePolicyActionLink ) </s>
