/** * * @param stdClass $params * @return \PHPMailer */ public static function getMailer($params = null) { $mailer = new \PHPMailer(); $mailer->IsSMTP(); // telling the class to use SMTP $mailer->Host = \Manager::getConf('mailer.smtpServer'); // SMTP server $mailer->From = \Manager::getConf('mailer.smtpFrom'); $mailer->FromName = \Manager::getConf('mailer.smtpFromName'); $mailer->CharSet = 'utf-8'; $mailer->WordWrap = 100; // Caso não esteja no servidor de produção ou não exista destinatário, // o destinatário passa a ser o email configurado no conf if (!\Manager::PROD() || !self::hasReceivers($params)) { $params->to = $params->cc = $params->bcc = \Manager::getConf('mailer.smtpTo'); } // Preenche os parametros do mailer. Ver atributos publicos da classe PHPMailer self::copyPublicAttributes($params, $mailer); $mailer->isHTML($params->isHTML); self::__AddAddress($params->to, $mailer); self::__AddCC($params->cc, $mailer); self::__AddBCC($params->bcc, $mailer); self::__AddReplyTo($params->ReplyTo, $mailer); return $mailer; }
public function init() { parent::init(); $this->idLanguage = Manager::getConf('options.language'); $msgDir = Manager::getAppPath('conf/report'); Manager::$msg->file = 'messages.' . $this->idLanguage . '.php'; Manager::$msg->addMessages($msgDir); }
public function init() { Manager::checkLogin(false); $this->idLanguage = Manager::getConf('fnbr20.lang'); $msgDir = Manager::getAppPath('conf/report'); Manager::$msg->file = 'messages.' . $this->idLanguage . '.php'; Manager::$msg->addMessages($msgDir); }
public function formEmail() { if (\Manager::getConf('mailer.smtpFrom')) { $this->data->desricaoConfFrom = '(' . \Manager::getConf('mailer.smtpFrom') . ')'; } if (\Manager::getConf('mailer.smtpTo')) { $this->data->desricaoConfTo = '(' . \Manager::getConf('mailer.smtpTo') . ')'; } $this->render(); }
public function onCreate() { parent::onCreate(); $this->formBox = new MBox(); /* as MFormAction */ $this->property->inline = Manager::getConf('ui.inlineFormAction') || $this->property->inline; /* as MFormBase */ $this->actions = array(); $this->menuAdded = false; $this->setRender('form'); }
/** * Brief Description. * Complete Description. * * @returns (tipo) desc * */ public function traceDump($msg, $file = '', $line = 0) { $message = $msg; if ($file != '') { $message .= " [file: {$file}] [line: {$line}]"; } $this->trace[] = $message; $tag = Manager::getConf('logs')['tag']; if (strlen($tag) > 0) { $this->log->logMessage('[' . $tag . ']' . $message); } else { $this->log->logMessage('[CUSTOM]' . $message); } }
public function load() { $report = 'repExemploCSV.jrxml'; $logo = Manager::getPublicPath('exemplos', '', 'images/logo.png'); $parametros['logo'] = $logo; //str_replace("/", "\\", $logo); $parametros['instituicao'] = Manager::getConf('instituicao'); $parametros['param1'] = $this->data->param1; $parametros['param2'] = $this->data->param2; $parametros['param3'] = $this->data->param3; $parametros['param4'] = $this->data->param4; $url = $this->executeCSV($this->data->result, $report, $parametros); $this->page->window($url); }
/** * * @param stdClass $params * @return \PHPMailer */ public static function getMailer($params = null) { $mailer = new \PHPMailer(); $mailer->IsSMTP(); // telling the class to use SMTP $mailer->Host = \Manager::getConf('maestro.mailer.smtpServer'); // SMTP server $mailer->From = $params->from ?: \Manager::getConf('maestro.mailer.smtpFrom'); $mailer->FromName = $params->fromName ?: \Manager::getConf('maestro.mailer.smtpFromName'); $mailer->Subject = $params->subject; $mailer->Body = $params->body; $mailer->CharSet = 'utf-8'; $mailer->WordWrap = $params->wordWrap ?: 100; $auth = \Manager::getConf('maestro.mailer.smtpAuth'); if ($auth) { $mailer->SMTPAuth = true; // Usa autenticação SMTP $mailer->SMTP_PORT = \Manager::getConf('maestro.mailer.smtpPort'); // Porta do servidor SMTP $mailer->Username = \Manager::getConf('maestro.mailer.smtpFrom'); // Usuário do servidor SMTP $mailer->Password = \Manager::getConf('maestro.mailer.smtpPass'); // Senha do servidor SMTP } // Caso não exista destinatário, // o destinatário passa a ser o email configurado no conf if (!self::hasReceivers($params)) { $params->to = $params->cc = $params->bcc = \Manager::getConf('maestro.mailer.smtpTo'); } // Preenche os parametros do mailer. Ver atributos publicos da classe PHPMailer self::copyPublicAttributes($params, $mailer); $mailer->isHTML($params->isHTML); // Preenche os destinatários $to = self::emailListToArray($params->to); $cc = self::emailListToArray($params->cc); $bcc = self::emailListToArray($params->bcc); foreach ($to as $address) { $mailer->AddAddress($address); } foreach ($cc as $address) { $mailer->AddCC($address); } foreach ($bcc as $address) { $mailer->AddBCC($address); } return $mailer; }
/** * Tenta se conectar à base Ldap de acordo com os dados em conf.php * @return boolean */ private function connect() { $this->host = \Manager::getConf('maestro.login.ldap.host'); $this->port = \Manager::getConf('maestro.login.ldap.port'); $this->user = \Manager::getConf('maestro.login.ldap.user'); $this->pass = \Manager::getConf('maestro.login.ldap.password'); $this->base = \Manager::getConf('maestro.login.ldap.base'); $this->conn = ldap_connect($this->host, $this->port); ldap_set_option($this->conn, LDAP_OPT_PROTOCOL_VERSION, 3); $r = ldap_bind($this->conn, $this->user, $this->pass); if (!$r) { $this->printLdapError('Error on ldap connection!'); exit; } mtrace('Abrindo conexao ao LDAP!'); return true; }
public function preProcess() { $frontController = $this->frontController; // exemplo de alteração da configuração dependendo do controller sendo executado $context = $frontController->getContext(); $controller = $context->getController(); if ($controller == 'controls') { Manager::setConf('session.check', false); } // é necessário validar a sessão? if (Manager::getConf('login.check') || Manager::getConf('session.check')) { $timeout = Manager::getSession()->checkTimeout(Manager::getConf('session.exception')); } if ($timeout) { $frontController->canCallHandler(false); $url = Manager::getURL(Manager::getApp() . '/main'); $frontController->setResult(new MRedirect(NULL, $url)); } }
public function checkTimeout($exception = false) { $timeout = Manager::getConf('maestro.session.timeout'); // If 0, we are not controling session if ($timeout != 0) { $timestamp = time(); $difftime = $timestamp - $this->default->timestamp; $this->timeout = $difftime > $timeout * 60; $this->default->timestamp = $timestamp; if ($this->timeout) { $this->destroy(); if ($exception) { throw new ETimeOutException(); } else { return true; } } } return false; }
public function checkAccess($transaction, $access, $deny = false) { //mdump($transaction); //mdump('--------------------'); //mdump($access); $module = Manager::getModule(); $ok = false; if (!is_numeric($access)) { $access = $this->access[$access]; } if ($this->auth->isLogged()) { $login = $this->auth->getLogin(); // MLogin object $transaction = strtoupper($transaction); // Transaction name $isAdmin = $login->isAdmin(); // Is administrator? $rights = (int) $login->getRights($transaction); // user rights $rightsInAll = (int) $login->getRights('ALL'); // user rights in all transactions $ok = ($rights & $access) == $access || ($rightsInAll & $access) == $access || $isAdmin; if (!$ok && $deny) { $msg = _M('Acesso Negado') . "<br><br>\n" . "<center><big><i><font color=red>" . _M('Transação: ') . "{$transaction}</font></i></big></center><br><br>\n" . _M('Informe um login válido para acessar esta página.') . "<br>"; //$go = Manager::getCurrentURL(); //$error = MPrompt::error($msg, $go, $caption, ''); //Manager::prompt($error, $deny); throw new ESecurityException($msg); } } else { if ($deny) { $currentUrl = urlencode(Manager::getCurrentURL()); $module = Manager::getConf('login.module'); $url = Manager::getURL("{$module}/main.login", array('return_to' => $currentUrl)); Manager::getPage()->redirect($url); } } return $ok; }
public function __construct($name = 'default') { try { $this->name = trim($name); $this->config = \Manager::getConf("maestro.db.{$name}"); $platform = self::$_platformMap[$this->config['driver']]; $this->platform = new $platform($this); $this->config['platform'] = $this->platform; $driver = self::$_driverClass[$this->config['driver']]; if ($driver != '') { $this->config['driverClass'] = $driver; unset($this->config['driver']); } $this->connection = $this->newConnection(); $this->params = $this->connection->getParams(); $this->platform->connect(); $ormLogger = $this->config['ormLoggerClass']; if ($ormLogger) { $this->ormLogger = new $ormLogger(); } } catch (\Exception $e) { throw new EDBException('Erro na conexão com o banco de dados.'); } }
public static function ORMMap() { return array('class' => \get_called_class(), 'database' => \Manager::getConf('fnbr20.db'), 'table' => 'auth_access', 'attributes' => array('idAccess' => array('column' => 'idAccess', 'key' => 'primary', 'idgenerator' => 'identity', 'type' => 'integer'), 'rights' => array('column' => 'rights', 'type' => 'integer'), 'idGroup' => array('column' => 'idGroup', 'type' => 'integer'), 'idTransaction' => array('column' => 'idTransaction', 'type' => 'integer')), 'associations' => array('group' => array('toClass' => 'auth\\models\\Group', 'cardinality' => 'oneToOne', 'keys' => 'idGroup:idGroup'), 'transaction' => array('toClass' => 'auth\\models\\Transaction', 'cardinality' => 'oneToOne', 'keys' => 'idTransaction:idTransaction'))); }
public static function ORMMap() { return array('class' => \get_called_class(), 'database' => \Manager::getConf('fnbr20.db'), 'table' => 'auth_person', 'attributes' => array('idPerson' => array('column' => 'idPerson', 'key' => 'primary', 'idgenerator' => 'identity', 'type' => 'integer'), 'name' => array('column' => 'name', 'type' => 'string'), 'email' => array('column' => 'email', 'type' => 'string'), 'nick' => array('column' => 'nick', 'type' => 'string')), 'associations' => array('users' => array('toClass' => 'auth\\models\\User', 'cardinality' => 'oneToMany', 'keys' => 'idPerson:idPerson'))); }
public static function ORMMap() { return array('class' => \get_called_class(), 'database' => \Manager::getConf('fnbr20.db'), 'table' => 'LU', 'attributes' => array('idLU' => array('column' => 'idLU', 'key' => 'primary', 'idgenerator' => 'identity', 'type' => 'integer'), 'name' => array('column' => 'name', 'type' => 'string'), 'senseDescription' => array('column' => 'senseDescription', 'type' => 'string'), 'active' => array('column' => 'active', 'type' => 'integer'), 'importNum' => array('column' => 'importNum', 'type' => 'integer'), 'incorporatedFE' => array('column' => 'incorporatedFE', 'type' => 'integer'), 'idEntity' => array('column' => 'idEntity', 'type' => 'integer'), 'idLemma' => array('column' => 'idLemma', 'type' => 'integer')), 'associations' => array('entity' => array('toClass' => 'fnbr20\\models\\Entity', 'cardinality' => 'oneToOne', 'keys' => 'idEntity:idEntity'), 'lemma' => array('toClass' => 'fnbr20\\models\\Lemma', 'cardinality' => 'oneToOne', 'keys' => 'idLemma:idLemma'))); }
public function __construct() { parent::__construct('page' . uniqid()); $this->scripts = new MScripts($this->name); $this->state = new MState($this->name); $this->action = Manager::getRequest()->getURL(); $this->actionChanged = false; $this->layout = mrequest('__LAYOUT') ?: 'default'; $this->fileUpload = mrequest('__ISFILEUPLOAD') == 'yes'; $this->content = new MContainerControl(); $template = mrequest('__TEMPLATE') ?: (Manager::getConf('theme.template') ?: 'index'); $this->setTemplateName($template); $this->setTemplate(); $this->theme = Manager::$conf['theme']['name']; $this->styleSheetCode = ''; ob_start(); }
public static function ORMMap() { return array('class' => \get_called_class(), 'database' => \Manager::getConf('fnbr20.db'), 'table' => 'WordForm', 'attributes' => array('idWordForm' => array('column' => 'idWordForm', 'key' => 'primary', 'idgenerator' => 'identity', 'type' => 'integer'), 'form' => array('column' => 'form', 'type' => 'string'), 'timeline' => array('column' => 'timeline', 'type' => 'string'), 'idLexeme' => array('column' => 'idLexeme', 'type' => 'integer')), 'associations' => array('lexeme' => array('toClass' => 'fnbr20\\models\\Lexeme', 'cardinality' => 'oneToOne', 'keys' => 'idLexeme:idLexeme'), 'timelines' => array('toClass' => 'fnbr20\\models\\Timeline', 'cardinality' => 'oneToMany', 'keys' => 'timeline:timeline'))); }
function fillDB($db, $fileInput, $fileOutput, $fileType, $parameters, $classPath, $save) { $params = $this->prepareParameters($parameters); $params->put('REPORT_LOCALE', new Java("java.util.Locale", 'pt', 'BR')); $extension = substr($fileInput, strrpos($fileInput, '.')); try { $sJfm = new JavaClass("net.sf.jasperreports.engine.JasperFillManager"); if ($extension == ".jrxml") { $s1 = new JavaClass("net.sf.jasperreports.engine.xml.JRXmlLoader"); $jasperDesign = $s1->load($fileInput); $sJcm = new JavaClass("net.sf.jasperreports.engine.JasperCompileManager"); $report = $sJcm->compileReport($jasperDesign); } else { $report = $fileInput; } // Create the JDBC Connection $conn = new Java("org.altic.jasperReports.JdbcConnection"); // Call the driver to be used $conn->setDriver(\Manager::getConf("db.{$db}.jdbc.driver")); // Connection URL $conn->setConnectString(\Manager::getConf("db.{$db}.jdbc.db")); // Server Connection Username $conn->setUser(\Manager::getConf("db.{$db}.user")); // Server Connection Password $conn->setPassword(\Manager::getConf("db.{$db}.password")); $print = $sJfm->fillReport($report, $params, $conn->getConnection()); $sJem = new JavaClass("net.sf.jasperreports.engine.JasperExportManager"); $output = \Manager::getDownloadURL('report', basename($this->fileOutput), true); $sJem->exportReportToPdfFile($print, $fileOutput); } catch (Exception $e) { dump_java_exception($e); } return $output; }
public static function ORMMap() { return array('class' => \get_called_class(), 'database' => \Manager::getConf('fnbr20.db'), 'table' => 'auth_transaction', 'attributes' => array('idTransaction' => array('column' => 'idTransaction', 'key' => 'primary', 'idgenerator' => 'identity', 'type' => 'integer'), 'name' => array('column' => 'name', 'type' => 'string'), 'description' => array('column' => 'description', 'type' => 'string')), 'associations' => array('accesss' => array('toClass' => 'auth\\models\\Access', 'cardinality' => 'oneToMany', 'keys' => 'idTransaction:idTransaction'))); }
public static function ORMMap() { return array('class' => \get_called_class(), 'database' => \Manager::getConf('fnbr20.db'), 'table' => 'Paragraph', 'attributes' => array('idParagraph' => array('column' => 'idParagraph', 'key' => 'primary', 'idgenerator' => 'identity', 'type' => 'integer'), 'documentOrder' => array('column' => 'documentOrder', 'type' => 'integer'), 'idDocument' => array('column' => 'idDocument', 'type' => 'integer')), 'associations' => array('document' => array('toClass' => 'fnbr20\\models\\Document', 'cardinality' => 'oneToOne', 'keys' => 'idDocument:idDocument'), 'sentences' => array('toClass' => 'fnbr20\\models\\Sentence', 'cardinality' => 'oneToMany', 'keys' => 'idParagraph:idParagraph'))); }
public static function ORMMap() { return array('class' => \get_called_class(), 'database' => \Manager::getConf('fnbr20.db'), 'table' => 'POS', 'attributes' => array('idPOS' => array('column' => 'idPOS', 'key' => 'primary', 'idgenerator' => 'identity', 'type' => 'integer'), 'POS' => array('column' => 'POS', 'type' => 'string'), 'entry' => array('column' => 'entry', 'type' => 'string'), 'idEntity' => array('column' => 'idEntity', 'type' => 'integer')), 'associations' => array('entity' => array('toClass' => 'fnbr20\\models\\Entity', 'cardinality' => 'oneToOne', 'keys' => 'idEntity:idEntity'), 'lemmas' => array('toClass' => 'fnbr20\\models\\Lemma', 'cardinality' => 'oneToMany', 'keys' => 'idPOS:idPOS'), 'lexemes' => array('toClass' => 'fnbr20\\models\\Lexeme', 'cardinality' => 'oneToMany', 'keys' => 'idPOS:idPOS'), 'entries' => array('toClass' => 'fnbr20\\models\\Entry', 'cardinality' => 'oneToMany', 'keys' => 'entry:entry'))); }
public static function ORMMap() { return array('class' => \get_called_class(), 'database' => \Manager::getConf('fnbr20.db'), 'table' => 'RelationType', 'attributes' => array('idRelationType' => array('column' => 'idRelationType', 'key' => 'primary', 'idgenerator' => 'identity', 'type' => 'integer'), 'entry' => array('column' => 'entry', 'type' => 'string'), 'nameEntity1' => array('column' => 'nameEntity1', 'type' => 'string'), 'nameEntity2' => array('column' => 'nameEntity2', 'type' => 'string'), 'idRelationGroup' => array('column' => 'idRelationGroup', 'type' => 'integer'), 'idDomain' => array('column' => 'idDomain', 'type' => 'integer')), 'associations' => array('domain' => array('toClass' => 'fnbr20\\models\\Domain', 'cardinality' => 'oneToOne', 'keys' => 'idDomain:idDomain'), 'relationgroup' => array('toClass' => 'fnbr20\\models\\RelationGroup', 'cardinality' => 'oneToOne', 'keys' => 'idRelationGroup:idRelationGroup'), 'entityrelations' => array('toClass' => 'fnbr20\\models\\EntityRelation', 'cardinality' => 'oneToMany', 'keys' => 'idRelationType:idRelationType'), 'entries' => array('toClass' => 'fnbr20\\models\\Entry', 'cardinality' => 'oneToMany', 'keys' => 'entry:entry'))); }
public static function ORMMap() { return array('class' => \get_called_class(), 'database' => \Manager::getConf('fnbr20.db'), 'table' => 'LayerType', 'attributes' => array('idLayerType' => array('column' => 'idLayerType', 'key' => 'primary', 'idgenerator' => 'identity', 'type' => 'integer'), 'entry' => array('column' => 'entry', 'type' => 'string'), 'allowsApositional' => array('column' => 'allowsApositional', 'type' => 'integer'), 'isAnnotation' => array('column' => 'isAnnotation', 'type' => 'integer'), 'order' => array('column' => '`order`', 'type' => 'integer'), 'idLayerGroup' => array('column' => 'idLayerGroup', 'type' => 'integer'), 'idEntity' => array('column' => 'idEntity', 'type' => 'integer')), 'associations' => array('layergroup' => array('toClass' => 'fnbr20\\models\\LayerGroup', 'cardinality' => 'oneToOne', 'keys' => 'idLayerGroup:idLayerGroup'), 'entity' => array('toClass' => 'fnbr20\\models\\Entity', 'cardinality' => 'oneToOne', 'keys' => 'idEntity:idEntity'), 'layers' => array('toClass' => 'fnbr20\\models\\Layer', 'cardinality' => 'oneToMany', 'keys' => 'idLayerType:idLayerType'), 'entries' => array('toClass' => 'fnbr20\\models\\Entry', 'cardinality' => 'oneToMany', 'keys' => 'entry:entry'))); }
public function sendEmail() { try { $time = Manager::getSysTime(); $ipaddress = $_SERVER['REMOTE_ADDR']; $mail = new PHPMailer(); $mail->IsSMTP(); // telling the class to use SMTP $mail->Host = Manager::getConf('mailer.smtpServer'); // SMTP server $mail->From = Manager::getConf('mailer.smtpFrom'); $mail->FromName = Manager::getConf('mailer.smtpFromName'); $mail->Subject = $this->data->assunto; $mail->isHTML(false); $mail->CharSet = 'utf-8'; $body = 'Enviada de: ' . $ipaddress . ' em ' . $time; $mail->Body = $body . "\n" . $this->data->mensagem; $mail->WordWrap = 100; $mail->addAddress($this->data->email); $ok = $mail->send(); $mail->clearAllRecipients(); $this->renderPrompt('information', 'Mensagem enviada com sucesso!'); } catch (Exception $e) { $this->renderPrompt('error', $e->getMessage()); } }
/** * Fetch the HTML template file and send to browser via redirect. * * @param string string the template file name * * @return string */ public function execute($file) { $html = $this->fetch($file); $fname = substr(uniqid(md5(uniqid(""))), 0, 10) . '.html'; $fileexp = Manager::home . '/' . Manager::getConf('home.reports') . '/' . $fname; $fp = fopen($fileexp, 'x'); fwrite($fp, $html); fclose($fp); $fileout = Manager::getActionURL('manager', 'reports:' . $fname); Manager::getPage()->window($fileout); }
public static function ORMMap() { return array('class' => \get_called_class(), 'database' => \Manager::getConf('fnbr20.db'), 'table' => 'EntityRelation', 'attributes' => array('idEntityRelation' => array('column' => 'idEntityRelation', 'key' => 'primary', 'idgenerator' => 'identity', 'type' => 'integer'), 'idRelationType' => array('column' => 'idRelationType', 'type' => 'integer'), 'idEntity1' => array('column' => 'idEntity1', 'type' => 'integer'), 'idEntity2' => array('column' => 'idEntity2', 'type' => 'integer'), 'idEntity3' => array('column' => 'idEntity3', 'type' => 'integer')), 'associations' => array('relationtype' => array('toClass' => 'fnbr20\\models\\RelationType', 'cardinality' => 'oneToOne', 'keys' => 'idRelationType:idRelationType'), 'entity1' => array('toClass' => 'fnbr20\\models\\Entity', 'cardinality' => 'oneToOne', 'keys' => 'idEntity1:idEntity'), 'entity2' => array('toClass' => 'fnbr20\\models\\Entity', 'cardinality' => 'oneToOne', 'keys' => 'idEntity2:idEntity'), 'entity3' => array('toClass' => 'fnbr20\\models\\Entity', 'cardinality' => 'oneToOne', 'keys' => 'idEntity3:idEntity'))); }
public function convertValue($value) { if (is_array($this->converter)) { foreach ($this->converter as $conv => $args) { $charset = \Manager::getConf("options.charset"); if ($conv == 'case') { if ($args == 'upper') { $value = mb_strtoupper($value, $charset); } elseif ($args == 'lower') { $value = mb_strtolower($value, $charset); } elseif ($args == 'ucwords') { $value = ucwords($value); } } else { if ($conv == 'trim') { if ($args == 'left') { $value = ltrim($value); } elseif ($args == 'right') { $value = rtrim($value); } elseif ($args == 'all') { $value = trim($value); } } else { if ($conv == 'default') { if ($value instanceof MType) { $rawValue = $value->getValue(); if ($rawValue == '') { $value->setValue($args); } } else { $value = $value ?: $args; } } } } } } return $value; }
public static function ORMMap() { return array('class' => \get_called_class(), 'database' => \Manager::getConf('fnbr20.db'), 'table' => 'view_frameelement', 'attributes' => array('idFrameElement' => array('column' => 'idFrameElement', 'key' => 'primary', 'type' => 'integer'), 'entry' => array('column' => 'entry', 'type' => 'string'), 'active' => array('column' => 'active', 'type' => 'integer'), 'idEntity' => array('column' => 'idEntity', 'type' => 'integer'), 'idColor' => array('column' => 'idColor', 'type' => 'integer'), 'typeEntry' => array('column' => 'typeEntry', 'type' => 'string'), 'idFrame' => array('column' => 'idFrame', 'type' => 'integer'), 'frameEntry' => array('column' => 'frameEntry', 'type' => 'string'), 'frameIdEntity' => array('column' => 'frameIdEntity', 'type' => 'integer')), 'associations' => array('entries' => array('toClass' => 'fnbr20\\models\\ViewEntryLanguage', 'cardinality' => 'oneToOne', 'keys' => 'entry:entry'), 'color' => array('toClass' => 'fnbr20\\models\\Color', 'cardinality' => 'oneToOne', 'keys' => 'idColor:idColor'))); }
public static function ORMMap() { return array('class' => \get_called_class(), 'database' => \Manager::getConf('fnbr20.db'), 'table' => 'AnnotationSet', 'attributes' => array('idAnnotationSet' => array('column' => 'idAnnotationSet', 'key' => 'primary', 'idgenerator' => 'identity', 'type' => 'integer'), 'timeline' => array('column' => 'timeline', 'type' => 'string'), 'idSubCorpus' => array('column' => 'idSubCorpus', 'type' => 'integer'), 'idSentence' => array('column' => 'idSentence', 'type' => 'integer'), 'idAnnotationStatus' => array('column' => 'idAnnotationStatus', 'type' => 'integer')), 'associations' => array('subcorpus' => array('toClass' => 'fnbr20\\models\\SubCorpus', 'cardinality' => 'oneToOne', 'keys' => 'idSubCorpus:idSubCorpus'), 'sentence' => array('toClass' => 'fnbr20\\models\\Sentence', 'cardinality' => 'oneToOne', 'keys' => 'idSentence:idSentence'), 'annotationStatus' => array('toClass' => 'fnbr20\\models\\TypeInstance', 'cardinality' => 'oneToOne', 'keys' => 'idAnnotationStatus:idTypeInstance'), 'layers' => array('toClass' => 'fnbr20\\models\\Layer', 'cardinality' => 'oneToMany', 'keys' => 'idAnnotationSet:idAnnotationSet'), 'timelines' => array('toClass' => 'fnbr20\\models\\Timeline', 'cardinality' => 'oneToMany', 'keys' => 'timeline:timeline'))); }