ServerOperation
Object Hierarchy:
Description:
Namespace: Gda
Package: libgda-5.0
Content:
Properties:
- public Connection connection { owned get; construct; }
- public int op_type { get; construct; }
- public ServerProvider provider { owned get; construct; }
- public string spec_filename { construct; }
Static methods:
- public static Quark error_quark ()
- public static unowned string op_type_to_string (ServerOperationType type)
Get a string version of
type
- public static ServerOperation? prepare_create_database (string provider, string? db_name) throws Error
Creates a new ServerOperation object which contains the specifications required to create a database.
- public static ServerOperation? prepare_create_table (Connection cnc, string table_name, Error error, ...)
Add more arguments if the flag needs them:
- public static ServerOperation? prepare_drop_database (string provider, string? db_name) throws Error
Creates a new ServerOperation object which contains the specifications required to drop a database.
- public static ServerOperation? prepare_drop_table (Connection cnc, string table_name) throws Error
This is just a convenient function to create a ServerOperation to drop a table in an opened connection.
- public static ServerOperationType string_to_op_type (string str)
Performs the reverse of op_type_to_string
Creation methods:
- public ServerOperation (ServerOperationType op_type, string xml_file)
IMPORTANT NOTE: Using this funtion is not the recommended way of creating a ServerOperation object, the correct way is to use create_operation; this method is reserved for the database provider's implementation.
Methods:
- public uint add_item_to_sequence (string seq_path)
- public bool del_item_from_sequence (string item_path)
- public unowned ServerOperationNode? get_node_info (string path_format, ...)
Get information about the node identified by
path
. - public string get_node_parent (string path)
Get the complete path to the parent of the node defined by
path
- public string get_node_path_portion (string path)
Get the last part of
path
- public ServerOperationNodeType get_node_type (string path, ServerOperationNodeStatus? status)
Convenience function to get the type of a node.
- public ServerOperationType get_op_type ()
Get the type of operation this is for
- public string[] get_root_nodes ()
Get an array of strings containing the paths of nodes situated at the root of this.
- public string[] get_sequence_item_names (string path)
Fetch the contents of a sequence.
- public uint get_sequence_max_size (string path)
- public uint get_sequence_min_size (string path)
- public unowned string get_sequence_name (string path)
- public uint get_sequence_size (string path)
- public string get_sql_identifier_at_path (Connection? cnc, ServerProvider? prov, string path)
This method is similar to get_value_at_format, but for SQL identifiers: a new string is returned instead of a Value.
- public unowned Value? get_value_at (string path)
Get the value for the node at the
path
path - public unowned Value? get_value_at_format (string path_format, ...)
Get the value for the node at the path formed using
path_format
and ... (the rules are the same as for to_string) - public bool is_valid (string? xml_file) throws Error
Tells if all the required values in this have been defined.
- public bool load_data_from_xml (unowned Node* node) throws Error
Loads the contents of
node
into this . - public bool perform_create_database (string? provider) throws Error
Creates a new database using the specifications in this.
- public bool perform_create_table () throws Error
Performs a prepared ServerOperation to create a table.
- public bool perform_drop_database (string? provider) throws Error
Destroys an existing database using the specifications in this.
- public bool perform_drop_table () throws Error
This is just a convenient function to perform a drop a table operation.
- public virtual void seq_item_added (string seq_path, int item_index)
- public virtual void seq_item_remove (string seq_path, int item_index)
- public bool set_value_at (string? value, string path) throws Error
Set the value for the node at the path formed using
path_format
and the ... ellipse (the rules are the same as for to_string).
Signals:
- public signal void sequence_item_added (string seq_path, int item_index)
Gets emitted whenever a new sequence item (from a sequence template) has been added
- public signal void sequence_item_remove (string seq_path, int item_index)
Gets emitted whenever a sequence item is about to be removed
Inherited Members:
All known members inherited from class GLib.Object