コード例 #1
0
 public function setUp()
 {
     $loader = new XMLLoader();
     $ETree = $loader->load(DATA_PATH . 'etree_result.pmml');
     $this->Xpath = new \DOMXPath($ETree);
     $this->ETreeRules = $this->Xpath->evaluate('//ETreeRules')->item(0);
 }
 public function __construct($DDPath)
 {
     $loader = new XMLLoader();
     $this->DD = $loader->load($DDPath);
     // init XPath
     $this->ddXpath = new \DOMXPath($this->DD);
     $this->ddXpath->registerNamespace('data', "http://keg.vse.cz/ns/datadescription0_2");
 }
コード例 #3
0
 protected function setUp()
 {
     $loader = new XMLLoader();
     $DD = $loader->load(DD);
     $DDP = new DataDescriptionParser($DD);
     $data = $DDP->parseData();
     $this->attributes = $data['DD']['transformationDictionary'];
     $FL = $loader->load(FL);
     $FLP = new FeatureListParser($FL, 'en');
     $data = $FLP->parseData();
     $this->coefficients = $data['BBA']['coefficients'];
 }
コード例 #4
0
 protected function setUp()
 {
     $loader = new XMLLoader();
     $this->ER = $loader->load(ERARQUERY);
     $DD = $loader->load(DD);
     $DDP = new DataDescriptionParser($DD);
     $data = $DDP->parseData();
     $this->attributes = $data['DD']['transformationDictionary'];
     $FL = $loader->load(FL);
     $FLP = new FeatureListParser($FL, 'en');
     $data = $FLP->parseData();
     $this->IMs = $data['interestMeasures'];
 }
コード例 #5
0
 protected function setUp()
 {
     $loader = new XMLLoader();
     $this->ER = $loader->load(ERTASKSETTING);
     $this->ERXPath = new DOMXPath($this->ER);
     $CP = new ConnectiveParser($this->ER, $this->ERXPath);
     $DD = $loader->load(DD);
     $DDP = new DataDescriptionParser($DD);
     $data = $DDP->parseData();
     $this->attributes = $data['DD']['transformationDictionary'];
     $FL = $loader->load(FL);
     $FLP = new FeatureListParser($FL, 'en');
     $data = $FLP->parseData();
     $this->IMs = $data['interestMeasures'];
     $this->DBAP = new DBAParser($this->ER, $this->ERXPath, $CP);
     $this->DBAP->parseDBAs();
     $this->BBAP = new BBAParser($this->ER, $this->ERXPath);
     $this->BBAP->parseBBAs();
 }
コード例 #6
0
 protected function setUp()
 {
     $this->ER = new \DOMDocument('1.0', 'UTF-8');
     $this->ER->load(ERARQUERY, LIBXML_NOBLANKS);
     $this->ERXPath = new \DOMXPath($this->ER);
     $CP = new ConnectiveParser($this->ER, $this->ERXPath);
     $loader = new XMLLoader();
     $DD = $loader->load(DD);
     $DDP = new DataDescriptionParser($DD);
     $data = $DDP->parseData();
     $this->attributes = $data['DD']['transformationDictionary'];
     $FL = $loader->load(FL);
     $FLP = new FeatureListParser($FL, 'en');
     $data = $FLP->parseData();
     $this->IMs = $data['interestMeasures'];
     $this->DBAP = new DBAParser($this->ER, $this->ERXPath, $CP);
     $this->DBAP->parseDBAs();
     $this->BBAP = new BBAParser($this->ER, $this->ERXPath);
     $this->BBAP->parseBBAs();
 }
コード例 #7
0
ファイル: DataParser.php プロジェクト: KIZI/sewebar-cms
 public function loadData()
 {
     $loader = new XMLLoader();
     $this->DD = $loader->load($this->DDPath);
     foreach ($this->FLPaths as $FLPath) {
         $FL = $loader->load($FLPath);
         array_push($this->FLs, $FL);
     }
     $this->FGC = $loader->load($this->FGCPath);
     $this->ER = $loader->load($this->ERPath);
     $this->ETree = $loader->load($this->ETreePath);
 }
コード例 #8
0
 protected function setUp()
 {
     $loader = new XMLLoader();
     $this->ERAssociationRules = $loader->load(ERASSOCIATIONRULES);
     $this->ERTaskSettingRules = $loader->load(ERTASKSETTING);
     $this->ERARQueryRules = $loader->load(ERARQUERY);
     $DD = $loader->load(DD);
     $DDP = new DataDescriptionParser($DD);
     $data = $DDP->parseData();
     $this->attributes = $data['DD']['transformationDictionary'];
     $FL = $loader->load(FL);
     $FLP = new FeatureListParser($FL, 'en');
     $data = $FLP->parseData();
     $this->IMs = $data['interestMeasures'];
 }
コード例 #9
0
 public function setUp()
 {
     $loader = new XMLLoader();
     $this->ETree = $loader->load(DATA_PATH . 'etree_result.pmml');
 }
コード例 #10
0
 public function setUp()
 {
     $loader = new XMLLoader();
     $FA = $loader->load(FA);
     $this->FAXpath = new \DOMXPath($FA);
 }
コード例 #11
0
 public function __construct($data)
 {
     $loader = new XMLLoader();
     $DOM = $loader->load($data);
     $this->XPath = new \DomXPath($DOM);
 }
コード例 #12
0
 protected function setUp()
 {
     $loader = new XMLLoader();
     $this->DD = $loader->load(DD);
 }
コード例 #13
0
require_once '../Bootstrap.php';
use IZI\Encoder\URLEncoder;
use IZI\FileLoader\XMLLoader;
$encoder = new URLEncoder();
$requestData = array('action' => 'getDocsNames', 'content' => '', 'id' => '');
$ch = curl_init();
curl_setopt($ch, CURLOPT_URL, 'http://nlp.vse.cz:8081/xquery_search/xquery_servlet');
curl_setopt($ch, CURLOPT_POSTFIELDS, $encoder->encode($requestData));
curl_setopt($ch, CURLOPT_VERBOSE, false);
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
curl_setopt($ch, CURLOPT_POST, true);
$response = curl_exec($ch);
$info = curl_getinfo($ch);
curl_close($ch);
$loader = new XMLLoader();
$result = $loader->load($response);
$xPath = new \DOMXPath($result);
$deletedCount = 0;
foreach ($xPath->evaluate('//doc') as $document) {
    $requestData = array('action' => 'deleteDocument', 'content' => '', 'id' => $document->nodeValue);
    $ch = curl_init();
    curl_setopt($ch, CURLOPT_URL, 'http://nlp.vse.cz:8081/xquery_search/xquery_servlet');
    curl_setopt($ch, CURLOPT_POSTFIELDS, $encoder->encode($requestData));
    curl_setopt($ch, CURLOPT_VERBOSE, false);
    curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
    curl_setopt($ch, CURLOPT_POST, true);
    $response = curl_exec($ch);
    $info = curl_getinfo($ch);
    curl_close($ch);
    $deletedCount++;