# Path: bridgepoint/ooaofooa.py
# class OoaOfOoaException(Exception):
# class Domain(xtuml.MetaModel):
# class ModelLoader(xtuml.ModelLoader):
#     def __init__(self, id_generator=None):
#     def add_symbol(self, name, handle):
#     def find_symbol(self, name):
# def is_contained_in(pe_pe, root):
# def is_global(pe_pe):
# def get_defining_component(pe_pe):
# def get_attribute_type(o_attr):
# def _get_data_type_name(s_dt):
# def _get_related_attributes(r_rgo, r_rto):
# def mk_enum(s_edt):
# def mk_bridge(metamodel, s_brg):
# def mk_external_entity(metamodel, s_ee):
# def mk_function(metamodel, s_sync):
# def mk_constant(cnst_syc):
# def mk_operation(metaclass, o_tfr):
# def mk_derived_attribute(metaclass, o_dbattr):
# def mk_class(m, o_obj, derived_attributes=False):
# def mk_simple_association(m, r_simp):
# def mk_linked_association(m, r_assoc):
#     def _mk_assoc(side1, side2):
# def mk_subsuper_association(m, r_subsup):
# def mk_derived_association(m, r_comp):
# def mk_association(m, r_rel):
# def mk_component(bp_model, c_c=None, derived_attributes=False):
#     def __init__(self, load_globals=True):
#     def filename_input(self, path_or_filename):
#     def build_component(self, name=None, derived_attributes=False):
# def _mk_loader(resource, load_globals):
# def load_metamodel(resource=None, load_globals=True):
# def load_component(resource, name=None, load_globals=True):
# def delete_globals(m, disconnect=False):
#     EE = collections.namedtuple(s_ee.Key_Lett, names)


import logging
import optparse
import sys
import xtuml
from bridgepoint import ooaofooa
    parser.set_description(__doc__.strip())
    
    parser.add_option("-r", "-R", dest="rel_ids", type='int', metavar="<number>",
                      help="limit consistency check to one or more associations",
                      action="append", default=[])

    parser.add_option("-k", dest="kinds", type='string', metavar="<key letter>",
                      help="limit check for uniqueness constraint violations to one or more classes",
                      action="append", default=[])
    
    parser.add_option("-g", "--globals", dest="globals",
                      help="add builtin global data types automatically, e.g. boolean, integer and real",
                      action="store_true", default=False)
                      
    parser.add_option("-v", "--verbosity", dest='verbosity', action="count",
                      help="increase debug logging level", default=1)
    
    (opts, args) = parser.parse_args(args)
    if len(args) == 0:
        parser.print_help()
        sys.exit(1)
        
    levels = {
              0: logging.ERROR,
              1: logging.WARNING,
              2: logging.INFO,
              3: logging.DEBUG,
    }
    logging.basicConfig(level=levels.get(opts.verbosity, logging.DEBUG))
    

# Path: bridgepoint/ooaofooa.py
# class OoaOfOoaException(Exception):
# class Domain(xtuml.MetaModel):
# class ModelLoader(xtuml.ModelLoader):
#     def __init__(self, id_generator=None):
#     def add_symbol(self, name, handle):
#     def find_symbol(self, name):
# def is_contained_in(pe_pe, root):
# def is_global(pe_pe):
# def get_defining_component(pe_pe):
# def get_attribute_type(o_attr):
# def _get_data_type_name(s_dt):
# def _get_related_attributes(r_rgo, r_rto):
# def mk_enum(s_edt):
# def mk_bridge(metamodel, s_brg):
# def mk_external_entity(metamodel, s_ee):
# def mk_function(metamodel, s_sync):
# def mk_constant(cnst_syc):
# def mk_operation(metaclass, o_tfr):
# def mk_derived_attribute(metaclass, o_dbattr):
# def mk_class(m, o_obj, derived_attributes=False):
# def mk_simple_association(m, r_simp):
# def mk_linked_association(m, r_assoc):
#     def _mk_assoc(side1, side2):
# def mk_subsuper_association(m, r_subsup):
# def mk_derived_association(m, r_comp):
# def mk_association(m, r_rel):
# def mk_component(bp_model, c_c=None, derived_attributes=False):
#     def __init__(self, load_globals=True):
#     def filename_input(self, path_or_filename):
#     def build_component(self, name=None, derived_attributes=False):
# def _mk_loader(resource, load_globals):
# def load_metamodel(resource=None, load_globals=True):
# def load_component(resource, name=None, load_globals=True):
# def delete_globals(m, disconnect=False):
#     EE = collections.namedtuple(s_ee.Key_Lett, names)


# Path: bridgepoint/consistency_check.py
import logging
import optparse
import sys
import xtuml
from bridgepoint import ooaofooa

    parser.set_description(__doc__.strip())
    
    parser.add_option("-r", "-R", dest="rel_ids", type='int', metavar="<number>",
                      help="limit consistency check to one or more associations",
                      action="append", default=[])

    parser.add_option("-k", dest="kinds", type='string', metavar="<key letter>",
                      help="limit check for uniqueness constraint violations to one or more classes",
                      action="append", default=[])
    
    parser.add_option("-g", "--globals", dest="globals",
                      help="add builtin global data types automatically, e.g. boolean, integer and real",
                      action="store_true", default=False)
                      
    parser.add_option("-v", "--verbosity", dest='verbosity', action="count",
                      help="increase debug logging level", default=1)
    
    (opts, args) = parser.parse_args(args)
    if len(args) == 0:
        parser.print_help()
        sys.exit(1)
        
    levels = {
              0: logging.ERROR,
              1: logging.WARNING,
              2: logging.INFO,
              3: logging.DEBUG,
    }
    logging.basicConfig(level=levels.get(opts.verbosity, logging.DEBUG))
    

    loader = ooaofooa.Loader(load_globals=opts.globals)