Blame view

php/RemoteDataCenter/FMI_HYBRID.php 1.72 KB
bf74fc2d   Elena.Budnik   IMPEX
1
2
3
4
5
6
7
8
9
10
11
12
13
<?php
/**
 * @class FMI_HYBRID
 * @brief  
 * @details
 */
class FMI_HYBRID extends SimulationDataCenterClass
{
	protected $url = "http://impex-fp7.fmi.fi/ws";
	protected $treeXML = "Tree_FMI_HYB.xml";
	protected $WSDL = "Methods_FMI.wsdl";
	
	protected $needsArgs = true;
bf74fc2d   Elena.Budnik   IMPEX
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
	public $interpolationMethod = array('Linear', 'NearestGridPoint');
	
	public $soapMethod = "getDataPointValue";
	public $soapMethodSpectra = "getDataPointSpectra";
	
	public $energyTableName = "EnergyRange", $tableTitle="Energy";
	
	//<xs:element minOccurs="0" maxOccurs="1" ref="EnergyChannel"/>
	
	// OutputFormat netCDF, VOTable, ASCII 
	public $outputFormat = "VOTable";
		
	protected function getDatasetName($no) 
	{
		$name = explode("/",trim($no->ResourceID));	  
		return end($name);	
	}
	
 	 
	protected function setSimulationRunNodeDescription($runNode,$sr)
	{
	   $coords = $this->getCoordinateSystem($sr->SimulationDomain->CoordinateSystem);
	   $domain = $this->getRegionBoundaries($sr->SimulationDomain,$sr->RegionParameter);
	   $properties = $this->getProperties($sr);
	   
		$runNode->setAttribute('desc', $coords.$domain.$properties);		 
	} 
	
	protected function getProperties($sr)
	{
		
 
	}
	
	protected function createSpecialArgs($dom)
	{
		$node = $dom->createElement('argument');
		$node->setAttribute('key', 'InterpolationMethod');
		$node->setAttribute('name', 'Interpolation Method');
		$node->setAttribute('type', 'list');
		$node->setAttribute('default', $this->interpolationMethod[0]);
		for ($i = 0; $i < 2; $i++)
		{
			$item = $dom->createElement('item');
			$item->setAttribute('key', $this->interpolationMethod[$i]);
			$item->setAttribute('name', $this->interpolationMethod[$i]);
			$node->appendChild($item);
		}
		return array($node);
	}
 
}
?>