acs_sc::contract::operation::delete (public)

 acs_sc::contract::operation::delete [ -operation_id operation_id ] \
    [ -contract_name contract_name ] \
    [ -operation_name operation_name ]

Defined in packages/acs-service-contract/tcl/contract-procs.tcl

Delete the operation.

Switches:
-operation_id (optional)
ID of the operation.
-contract_name (optional)
Name of the contract.
-operation_name (optional)
Name of the operation.

Partial Call Graph (max 5 caller/called nodes):
%3 test_acs_sc_impl_new_from_spec acs_sc_impl_new_from_spec (test acs-service-contract) acs_sc::contract::operation::delete acs_sc::contract::operation::delete test_acs_sc_impl_new_from_spec->acs_sc::contract::operation::delete acs_sc::msg_type::delete acs_sc::msg_type::delete (private) acs_sc::contract::operation::delete->acs_sc::msg_type::delete db_1row db_1row (public) acs_sc::contract::operation::delete->db_1row db_dml db_dml (public) acs_sc::contract::operation::delete->db_dml acs_sc::contract::delete acs_sc::contract::delete (public) acs_sc::contract::delete->acs_sc::contract::operation::delete

Testcases:
acs_sc_impl_new_from_spec
Source code:
    if { $operation_id eq "" && ( $contract_name eq "" || $operation_name eq "" ) } {
        error "You must supply either contract_name and operation_name, or operation_id"
    }

    db_1row get_operation {
        select operation_id,
               operation_inputtype_id,
               operation_outputtype_id
        from   acs_sc_operations
        where operation_id = :operation_id or
              (:operation_id is null
               and contract_name = :contract_name
               and operation_name = :operation_name)
    }

    db_dml delete_operation {
        delete from acs_sc_operations
        where operation_id = :operation_id
    }

    set msg_types [list  $operation_inputtype_id  $operation_outputtype_id]

    # Delete msg types
    foreach msg_type_id $msg_types {
        if { $msg_type_id ne "" } {
            acs_sc::msg_type::delete -msg_type_id $msg_type_id
        }
    }
XQL Not present:
Generic
PostgreSQL XQL file:
packages/acs-service-contract/tcl/contract-procs-postgresql.xql

Oracle XQL file:
packages/acs-service-contract/tcl/contract-procs-oracle.xql

[ hide source ] | [ make this the default ]
Show another procedure: