diff options
| author | Yoggzo <yogg@epsina.com> | 2016-04-21 21:51:46 +0200 |
|---|---|---|
| committer | Yoggzo <yogg@epsina.com> | 2016-04-21 21:51:46 +0200 |
| commit | 3f6af0b6446725462362de94f09daf9a723b130d (patch) | |
| tree | 2cae5a13c6bd98a236ac147d5e8c7572017af27f /server/core | |
| parent | 94ce37f5175eb6f528d5ad29a446c04d981628f1 (diff) | |
modification in structure for ip and routers
Diffstat (limited to 'server/core')
| -rwxr-xr-x | server/core/App.php | 2 | ||||
| -rwxr-xr-x | server/core/Automating.php | 5 | ||||
| -rwxr-xr-x | server/core/NetworkLayer3.php (renamed from server/core/FloatingIp.php) | 12 |
3 files changed, 10 insertions, 9 deletions
diff --git a/server/core/App.php b/server/core/App.php index a4be6ec..32ad016 100755 --- a/server/core/App.php +++ b/server/core/App.php @@ -64,7 +64,7 @@ class App{ $opt = $this->tokenClass->getOptions($service);
return $this->openstack->computeV2($opt);
break;
- case "FloatingIp":
+ case "NetworkLayer3":
if($this->tokenPost == NULL) $this->tokenClass->genNetworkToken();
$opt = $this->tokenClass->getOptions('Network');
return $this->openstack->networkingV2ExtLayer3($opt);
diff --git a/server/core/Automating.php b/server/core/Automating.php index 69a2773..4e212e7 100755 --- a/server/core/Automating.php +++ b/server/core/Automating.php @@ -14,6 +14,7 @@ include("CoreInterface.php"); include("Image.php"); include("Network.php"); include("Compute.php"); +include("NetworkLayer3"); class automating implements Core{ @@ -22,7 +23,7 @@ class automating implements Core{ protected $appImage; protected $appNetwork; protected $appIdentity; - protected $appFloatingIp; + protected $appNetworkLayer3; protected $app; /** @@ -40,7 +41,7 @@ class automating implements Core{ $this->appImage = $appImage; $this->appNetwork = $appNetwork; $this->appIdentity = $appIdentity; - $this->appFloatingIp = $appFloatingIp; + $this->appNetworkLayer3 = $appNetworkLayer3; $this->app = $app; } diff --git a/server/core/FloatingIp.php b/server/core/NetworkLayer3.php index cdbb64b..28d27b4 100755 --- a/server/core/FloatingIp.php +++ b/server/core/NetworkLayer3.php @@ -22,7 +22,7 @@ use OpenCloud\Common\Error\UserInputError; * Management of images * */ -class floatingIp { +class networkLayer3 { /** @var App $app protected, contains the main app object */ protected $app; @@ -35,14 +35,14 @@ class floatingIp { * * @param App $app the main app object * - * @return floatingip + * @return networkLayer3 */ public function __construct($app){ if(!isset($app)){ $this->app->setOutput("Error", "Incorrect parameter app"); } $this->app = $app; - $this->libClass = $app->getLibClass("FloatingIp"); + $this->libClass = $app->getLibClass("NetworkLayer3"); } @@ -72,7 +72,7 @@ class floatingIp { $result[] = $tmp; } - $this->app->setOutput("FloatingIp", $result); + $this->app->setOutput("NetworkLayer3", $result); }catch(BadResponseError $e){ $this->app->getErrorInstance()->BadResponseHandler($e); }catch(UserInputError $e){ @@ -105,7 +105,7 @@ class floatingIp { if(!isset($floatingip)){ $this->app->setOutput("Error", "Unknowing error during floating ip creation"); }else{ - $this->app->setOutput("FloatingIp", $floatingip); + $this->app->setOutput("NetworkLayer3", $floatingip); } }catch(BadResponseError $e){ echo $e."</br>"; @@ -160,7 +160,7 @@ class floatingIp { $this->app->setOutput("Error", "Unknow id"); }else{ // If id exists $res = $this->libClass->getFloatingIp($id); - $this->app->setOutput("FloatingIp", $res); + $this->app->setOutput("NetworkLayer3", $res); } }catch(BadResponseError $e){ |
