BayEOS-PHP
 All Data Structures Namespaces Files Functions Variables Pages
MyClient.php
Go to the documentation of this file.
1 #!/usr/bin/php
2 <?php
3 $options=array('bayeosgateway_url'=>
4  'http://bayconf.bayceer.uni-bayreuth.de/gateway/frame/saveFlat',
5  'bayeosgateway_pw'=>'import',
6  'bayeosgateway_user'=>'import');
7 $names=array('PHP-TestDevice1','PHP-TestDevice2');
8 
9 require_once 'BayEOSGatewayClient.php';
10 /*
11  * extend the BayEOSGatewayClient-Class with a own
12  * implementation of readData($name)
13  */
15  //Generate Data:
16  protected function readData(){
17  if($this->names[$this->i]=='PHP-TestDevice1')
18  return FALSE;
19  else
20  return array(2,1.0,rand(-1,1));
21 
22  }
23 }
24 
25 //Create a Instance
27 
28 //Run the client
29 $client->run();
30 
31 ?>
$options
Definition: MyClient.php:3
$client
Definition: MyClient.php:26
$names
Definition: MyClient.php:7