Linux and UNIX Man Pages

Linux & Unix Commands - Search Man Pages

sqlheavy-gen-orm(1) [debian man page]

sqlheavy-gen-orm(1)						     SQLHeavy						       sqlheavy-gen-orm(1)

NAME
sqlheavy-gen-orm - SQLHeavy ORM Generator SYNOPSIS
sqlheavy-gen-orm [OPTION...] SOURCE... DESCRIPTION
This tool will generate a Vala file which provides an object for each table in the specified database(s), each of which extends the SQL- HeavyRecord class. You should pass at least one SQLite database file, which it will examine to produce the output. Additionally, you can specifiy metadata files (which is a key file), as well as vala files to provide custom code in the output. OPTIONS
--help -o, --output=FILE Write output to FILE (defaults to stdout) -m, --metadata=FILE Load metadata from FILE --vapidir=DIRECTORY Look for package bindings in DIRECTORY --pkg=PACKAGE Include binding for PACKAGE -o, --output=FILE Output to FILE (default is stdout) -p, --properties Write properties instead of methods METADATA FORMAT
The concept of the metadata files is similar to that of vapigen (in fact, the entire sqlheavy-gen-orm tool is largely inspired by vapigen), but it uses the key file format so that it can use the GLib Key-Value file parser. Databases, tables, and columns are all represented by groups, each of which may have any number of properties (the key value pairs). Selectors The format for the selectors is relatively straightforward. A forward slash ("/") is used as the separator character, and prepending an @ to a token means that token refers to a database, and prepending a % means that token refers to a table. The database name is the name of the database file, not including the last dot character and anything following it (i.e., the extension). An asterisk can be used as a wild- card. Several examples, as well as an explanation of each: @foo/bar/baz The baz symbol in the bar table in the foo database. @foo The foo database %bar/baz The baz column in the bar table in any database baz The baz column in any table in any database @foo/*/baz The baz column in any table in the foo database */bar The bar table in any database Properties Properties are represented by key-value pairs. The following is a table of currently implemented properties: +-------+--------+------------+---------------------------------+ | Name | Type | DB/TBL/COL | Purpose | +-------+--------+------------+---------------------------------+ |name | string | Y/Y/Y | Rename the symbol | |type | string | N/N/Y | Set the Vala type of the column | |hidden | bool | Y/Y/Y | Do not create a binding | +-------+--------+------------+---------------------------------+ Custom Vala In addition to providing one or more SQLite database as a basis for code generation, you can provide an existing *.vala file. Theoreti- cally, this will allow you to place custom code in a separate file, so that you can use sqlheavy-gen-orm to update the generated code with- out losing whenever the database schema changes, and you will not lose any enhancements you made. The generated code will be merged into the custom vala file in order to generate the output. HOMEPAGE AND BUG REPORT
http://code.google.com/p/sqlheavy AUTHORS
Evan Nemerson sqlheavy-gen-orm-0.0.1 29 April 2010 sqlheavy-gen-orm(1)

Check Out this Related Man Page

STAG-DIFF(1p)						User Contributed Perl Documentation					     STAG-DIFF(1p)

NAME
stag-diff - finds the difference between two stag files SYNOPSIS
stag-diff -ignore foo-id -ignore bar-id file1.xml file2.xml DESCRIPTION
Compares two data trees and reports whether they match. If they do not match, the mismatch is reported. ARGUMENTS -help|h shows this document -ignore|i ELEMENT these nodes are ignored for the purposes of comparison. Note that attributes are treated as elements, prefixed by the containing element id. For example, if you have <foo ID="wibble"> And you wish to ignore the ID attribute, then you would use the switch -ignore foo-ID You can specify multiple elements to ignore like this -i foo -i bar -i baz You can also specify paths -i foo/bar/bar-id -parser|p FORMAT which parser to use. The default is XML. This can also be autodetected by the file suffix. Other alternatives are sxpr and itext. See Data::Stag for details. -report|r ELEMENT report mismatches as they occur on each element of type ELEMENT multiple elements can be specified -verbose|v used in conjunction with the -report switch shows the tree of the mismatching element OUTPUT If a mismatch is reported, a report is generated displaying the subpart of the tree that could not be matched. This will look like this: REASON: no_matching_node: annotation no_matching_node: feature_set no_matching_node: feature_span no_matching_node: evidence no_matching_node: evidence-id data_mismatch(:15077290 ne :15077291): evidence-id AND evidence-id Due to the nature of tree matching, it can be difficult to specify exactly how trees do not match. To investigate this, you may need to use the -r and -v options. For the above output, I would recommend using stag-diff -r feature_span -v ALGORITHM Both trees are recursively traversed... see the actual code for how this works The order of elements is not important; eg <foo> <bar> <baz>1</baz> </bar> <bar> <baz>2</baz> </bar> </foo> matches <foo> <bar> <baz>2</baz> </bar> <bar> <baz>1</baz> </bar> </foo> The recursive nature of this algorithm means that certain tree comparisons will explode wrt time and memory. I think this will only happen with very deep trees where nodes high up in the tree can only be differentiated by nodes low down in the tree. Both trees are loaded into memory to begin with, so it may thrash with very large documents AUTHOR Chris Mungall cjm at fruitfly dot org SEE ALSO
Data::Stag perl v5.10.0 2008-12-23 STAG-DIFF(1p)
Man Page