Commit 93878dc5 authored by Spiros Koulouzis's avatar Spiros Koulouzis

create new topology if scaling

parent 8c591094
......@@ -72,7 +72,7 @@
<h1 class="page-header">Files and Libraries</h1>
<h3 id="artifact_gwt_json_overlay">GWT JSON Overlay</h3>
<p class="lead">Created November 21, 2017</p>
<p class="lead">Created November 22, 2017</p>
<p> <p>
The <a href="http://code.google.com/webtoolkit/">Google Web Toolkit</a> JSON Overlay library provides the JSON Overlays that
can be used to access the Web service API for this application.
......@@ -97,7 +97,7 @@
</tbody>
</table>
<h3 id="artifact_java_json_client_library">Java JSON Client Library</h3>
<p class="lead">Created November 21, 2017</p>
<p class="lead">Created November 22, 2017</p>
<p><p>
The Java client-side library is used to provide the set of Java objects that can be serialized
to/from JSON using <a href="http://jackson.codehaus.org/">Jackson</a>. This is useful for accessing the
......@@ -127,7 +127,7 @@
</tbody>
</table>
<h3 id="artifact_java_xml_client_library">Java XML Client Library</h3>
<p class="lead">Created November 21, 2017</p>
<p class="lead">Created November 22, 2017</p>
<p><p>
The Java client-side library is used to access the Web service API for this application using Java.
</p>
......@@ -155,7 +155,7 @@
</tbody>
</table>
<h3 id="artifact_js_client_library">JavaScript Client Library</h3>
<p class="lead">Created November 21, 2017</p>
<p class="lead">Created November 22, 2017</p>
<p><p>
The JavaScript client-side library defines classes that can be (de)serialized to/from JSON.
This is useful for accessing the resources that are published by this application, but only
......@@ -184,13 +184,13 @@
<tbody data-link="row" class="rowlink">
<tr class="clickable-row" data-href="drip-api-js.zip">
<td><span class="downloadfile-name">drip-api-js.zip</span></td>
<td><span class="downloadfile-size">5.91K</span></td>
<td><span class="downloadfile-size">5.92K</span></td>
<td><span class="downloadfile-description">&nbsp;</span></td>
</tr>
</tbody>
</table>
<h3 id="artifact_php_json_client_library">PHP JSON Client Library</h3>
<p class="lead">Created November 21, 2017</p>
<p class="lead">Created November 22, 2017</p>
<p><p>
The PHP JSON client-side library defines the PHP classes that can be (de)serialized to/from JSON.
This is useful for accessing the resources that are published by this application, but only
......@@ -213,13 +213,13 @@
<tbody data-link="row" class="rowlink">
<tr class="clickable-row" data-href="drip-api-php.zip">
<td><span class="downloadfile-name">drip-api-php.zip</span></td>
<td><span class="downloadfile-size">6.58K</span></td>
<td><span class="downloadfile-size">6.77K</span></td>
<td><span class="downloadfile-description">&nbsp;</span></td>
</tr>
</tbody>
</table>
<h3 id="artifact_php_xml_client_library">PHP XML Client Library</h3>
<p class="lead">Created November 21, 2017</p>
<p class="lead">Created November 22, 2017</p>
<p><p>
The PHP client-side library defines the PHP classes that can be (de)serialized to/from XML.
This is useful for accessing the resources that are published by this application, but only
......@@ -251,7 +251,7 @@
</tbody>
</table>
<h3 id="artifact_ruby_json_client_library">Ruby JSON Client Library</h3>
<p class="lead">Created November 21, 2017</p>
<p class="lead">Created November 22, 2017</p>
<p><p>
The Ruby JSON client-side library defines the Ruby classes that can be (de)serialized to/from JSON.
This is useful for accessing the REST endpoints that are published by this application, but only
......
......@@ -93,208 +93,92 @@ module V1
module External
module Ansible
# (no documentation provided)
class AnsibleResult
class DeployParameter
# (no documentation provided)
attr_accessor :msg
# (no documentation provided)
attr_accessor :changed
# (no documentation provided)
attr_accessor :end
# (no documentation provided)
attr_accessor :stdout
# (no documentation provided)
attr_accessor :cmd
# (no documentation provided)
attr_accessor :start
# (no documentation provided)
attr_accessor :stderr
# (no documentation provided)
attr_accessor :delta
# the IP
attr_accessor :IP
# the user
attr_accessor :user
# the role
attr_accessor :role
# the json hash for this AnsibleResult
# the json hash for this DeployParameter
def to_jaxb_json_hash
_h = {}
_h['msg'] = msg.to_jaxb_json_hash unless msg.nil?
_h['changed'] = changed.to_jaxb_json_hash unless changed.nil?
_h['end'] = end.to_jaxb_json_hash unless end.nil?
_h['stdout'] = stdout.to_jaxb_json_hash unless stdout.nil?
if !cmd.nil?
_ha = Array.new
cmd.each { | _item | _ha.push _item.to_jaxb_json_hash }
_h['cmd'] = _ha
end
_h['start'] = start.to_jaxb_json_hash unless start.nil?
_h['stderr'] = stderr.to_jaxb_json_hash unless stderr.nil?
_h['delta'] = delta.to_jaxb_json_hash unless delta.nil?
_h['IP'] = IP.to_jaxb_json_hash unless IP.nil?
_h['user'] = user.to_jaxb_json_hash unless user.nil?
_h['role'] = role.to_jaxb_json_hash unless role.nil?
return _h
end
# the json (string form) for this AnsibleResult
# the json (string form) for this DeployParameter
def to_json
to_jaxb_json_hash.to_json
end
#initializes this AnsibleResult with a json hash
#initializes this DeployParameter with a json hash
def init_jaxb_json_hash(_o)
if !_o['msg'].nil?
_oa = _o['msg']
if(_oa.is_a? Hash)
@msg = EnunciateHelpers::LAMB_CLASS_AWARE.call(_oa) if _oa['@class']
@msg = String.from_json(_oa) unless _oa['@class']
elsif (_oa.is_a? Array)
#an array(of hashes hopefully) or scalar
@msg = Array.new
_oa.each { | _item |
if ((_item.nil? || _item['@class'].nil?)rescue true)
@msg.push String.from_json(_item)
else
@msg.push EnunciateHelpers::LAMB_CLASS_AWARE.call(_item)
end
}
else
@msg = _oa
end
end
if !_o['changed'].nil?
_oa = _o['changed']
if(_oa.is_a? Hash)
@changed = EnunciateHelpers::LAMB_CLASS_AWARE.call(_oa) if _oa['@class']
@changed = Boolean.from_json(_oa) unless _oa['@class']
elsif (_oa.is_a? Array)
#an array(of hashes hopefully) or scalar
@changed = Array.new
_oa.each { | _item |
if ((_item.nil? || _item['@class'].nil?)rescue true)
@changed.push Boolean.from_json(_item)
else
@changed.push EnunciateHelpers::LAMB_CLASS_AWARE.call(_item)
end
}
else
@changed = _oa
end
end
if !_o['end'].nil?
_oa = _o['end']
if(_oa.is_a? Hash)
@end = EnunciateHelpers::LAMB_CLASS_AWARE.call(_oa) if _oa['@class']
@end = Time.from_json(_oa) unless _oa['@class']
elsif (_oa.is_a? Array)
#an array(of hashes hopefully) or scalar
@end = Array.new
_oa.each { | _item |
if ((_item.nil? || _item['@class'].nil?)rescue true)
@end.push Time.from_json(_item)
else
@end.push EnunciateHelpers::LAMB_CLASS_AWARE.call(_item)
end
}
else
@end = _oa
end
end
if !_o['stdout'].nil?
_oa = _o['stdout']
if(_oa.is_a? Hash)
@stdout = EnunciateHelpers::LAMB_CLASS_AWARE.call(_oa) if _oa['@class']
@stdout = String.from_json(_oa) unless _oa['@class']
elsif (_oa.is_a? Array)
#an array(of hashes hopefully) or scalar
@stdout = Array.new
_oa.each { | _item |
if ((_item.nil? || _item['@class'].nil?)rescue true)
@stdout.push String.from_json(_item)
else
@stdout.push EnunciateHelpers::LAMB_CLASS_AWARE.call(_item)
end
}
else
@stdout = _oa
end
end
if !_o['cmd'].nil?
_oa = _o['cmd']
if(_oa.is_a? Hash)
@cmd = EnunciateHelpers::LAMB_CLASS_AWARE.call(_oa) if _oa['@class']
@cmd = String.from_json(_oa) unless _oa['@class']
elsif (_oa.is_a? Array)
#an array(of hashes hopefully) or scalar
@cmd = Array.new
_oa.each { | _item |
if ((_item.nil? || _item['@class'].nil?)rescue true)
@cmd.push String.from_json(_item)
else
@cmd.push EnunciateHelpers::LAMB_CLASS_AWARE.call(_item)
end
}
else
@cmd = _oa
end
end
if !_o['start'].nil?
_oa = _o['start']
if !_o['IP'].nil?
_oa = _o['IP']
if(_oa.is_a? Hash)
@start = EnunciateHelpers::LAMB_CLASS_AWARE.call(_oa) if _oa['@class']
@start = Time.from_json(_oa) unless _oa['@class']
@IP = EnunciateHelpers::LAMB_CLASS_AWARE.call(_oa) if _oa['@class']
@IP = String.from_json(_oa) unless _oa['@class']
elsif (_oa.is_a? Array)
#an array(of hashes hopefully) or scalar
@start = Array.new
@IP = Array.new
_oa.each { | _item |
if ((_item.nil? || _item['@class'].nil?)rescue true)
@start.push Time.from_json(_item)
@IP.push String.from_json(_item)
else
@start.push EnunciateHelpers::LAMB_CLASS_AWARE.call(_item)
@IP.push EnunciateHelpers::LAMB_CLASS_AWARE.call(_item)
end
}
else
@start = _oa
@IP = _oa
end
end
if !_o['stderr'].nil?
_oa = _o['stderr']
if !_o['user'].nil?
_oa = _o['user']
if(_oa.is_a? Hash)
@stderr = EnunciateHelpers::LAMB_CLASS_AWARE.call(_oa) if _oa['@class']
@stderr = String.from_json(_oa) unless _oa['@class']
@user = EnunciateHelpers::LAMB_CLASS_AWARE.call(_oa) if _oa['@class']
@user = String.from_json(_oa) unless _oa['@class']
elsif (_oa.is_a? Array)
#an array(of hashes hopefully) or scalar
@stderr = Array.new
@user = Array.new
_oa.each { | _item |
if ((_item.nil? || _item['@class'].nil?)rescue true)
@stderr.push String.from_json(_item)
@user.push String.from_json(_item)
else
@stderr.push EnunciateHelpers::LAMB_CLASS_AWARE.call(_item)
@user.push EnunciateHelpers::LAMB_CLASS_AWARE.call(_item)
end
}
else
@stderr = _oa
@user = _oa
end
end
if !_o['delta'].nil?
_oa = _o['delta']
if !_o['role'].nil?
_oa = _o['role']
if(_oa.is_a? Hash)
@delta = EnunciateHelpers::LAMB_CLASS_AWARE.call(_oa) if _oa['@class']
@delta = Time.from_json(_oa) unless _oa['@class']
@role = EnunciateHelpers::LAMB_CLASS_AWARE.call(_oa) if _oa['@class']
@role = String.from_json(_oa) unless _oa['@class']
elsif (_oa.is_a? Array)
#an array(of hashes hopefully) or scalar
@delta = Array.new
@role = Array.new
_oa.each { | _item |
if ((_item.nil? || _item['@class'].nil?)rescue true)
@delta.push Time.from_json(_item)
@role.push String.from_json(_item)
else
@delta.push EnunciateHelpers::LAMB_CLASS_AWARE.call(_item)
@role.push EnunciateHelpers::LAMB_CLASS_AWARE.call(_item)
end
}
else
@delta = _oa
@role = _oa
end
end
end
# constructs a AnsibleResult from a (parsed) JSON hash
# constructs a DeployParameter from a (parsed) JSON hash
def self.from_json(o)
if o.nil?
return nil
......@@ -324,8 +208,6 @@ end
end
end
module Nl
module Uva
......@@ -477,92 +359,208 @@ module V1
module External
module Ansible
# (no documentation provided)
class DeployParameter
class AnsibleResult
# the IP
attr_accessor :IP
# the user
attr_accessor :user
# the role
attr_accessor :role
# (no documentation provided)
attr_accessor :msg
# (no documentation provided)
attr_accessor :changed
# (no documentation provided)
attr_accessor :end
# (no documentation provided)
attr_accessor :stdout
# (no documentation provided)
attr_accessor :cmd
# (no documentation provided)
attr_accessor :start
# (no documentation provided)
attr_accessor :stderr
# (no documentation provided)
attr_accessor :delta
# the json hash for this DeployParameter
# the json hash for this AnsibleResult
def to_jaxb_json_hash
_h = {}
_h['IP'] = IP.to_jaxb_json_hash unless IP.nil?
_h['user'] = user.to_jaxb_json_hash unless user.nil?
_h['role'] = role.to_jaxb_json_hash unless role.nil?
_h['msg'] = msg.to_jaxb_json_hash unless msg.nil?
_h['changed'] = changed.to_jaxb_json_hash unless changed.nil?
_h['end'] = end.to_jaxb_json_hash unless end.nil?
_h['stdout'] = stdout.to_jaxb_json_hash unless stdout.nil?
if !cmd.nil?
_ha = Array.new
cmd.each { | _item | _ha.push _item.to_jaxb_json_hash }
_h['cmd'] = _ha
end
_h['start'] = start.to_jaxb_json_hash unless start.nil?
_h['stderr'] = stderr.to_jaxb_json_hash unless stderr.nil?
_h['delta'] = delta.to_jaxb_json_hash unless delta.nil?
return _h
end
# the json (string form) for this DeployParameter
# the json (string form) for this AnsibleResult
def to_json
to_jaxb_json_hash.to_json
end
#initializes this DeployParameter with a json hash
#initializes this AnsibleResult with a json hash
def init_jaxb_json_hash(_o)
if !_o['IP'].nil?
_oa = _o['IP']
if !_o['msg'].nil?
_oa = _o['msg']
if(_oa.is_a? Hash)
@IP = EnunciateHelpers::LAMB_CLASS_AWARE.call(_oa) if _oa['@class']
@IP = String.from_json(_oa) unless _oa['@class']
@msg = EnunciateHelpers::LAMB_CLASS_AWARE.call(_oa) if _oa['@class']
@msg = String.from_json(_oa) unless _oa['@class']
elsif (_oa.is_a? Array)
#an array(of hashes hopefully) or scalar
@IP = Array.new
@msg = Array.new
_oa.each { | _item |
if ((_item.nil? || _item['@class'].nil?)rescue true)
@IP.push String.from_json(_item)
@msg.push String.from_json(_item)
else
@IP.push EnunciateHelpers::LAMB_CLASS_AWARE.call(_item)
@msg.push EnunciateHelpers::LAMB_CLASS_AWARE.call(_item)
end
}
else
@IP = _oa
@msg = _oa
end
end
if !_o['user'].nil?
_oa = _o['user']
if !_o['changed'].nil?
_oa = _o['changed']
if(_oa.is_a? Hash)
@user = EnunciateHelpers::LAMB_CLASS_AWARE.call(_oa) if _oa['@class']
@user = String.from_json(_oa) unless _oa['@class']
@changed = EnunciateHelpers::LAMB_CLASS_AWARE.call(_oa) if _oa['@class']
@changed = Boolean.from_json(_oa) unless _oa['@class']
elsif (_oa.is_a? Array)
#an array(of hashes hopefully) or scalar
@user = Array.new
@changed = Array.new
_oa.each { | _item |
if ((_item.nil? || _item['@class'].nil?)rescue true)
@user.push String.from_json(_item)
@changed.push Boolean.from_json(_item)
else
@user.push EnunciateHelpers::LAMB_CLASS_AWARE.call(_item)
@changed.push EnunciateHelpers::LAMB_CLASS_AWARE.call(_item)
end
}
else
@user = _oa
@changed = _oa
end
end
if !_o['role'].nil?
_oa = _o['role']
if !_o['end'].nil?
_oa = _o['end']
if(_oa.is_a? Hash)
@role = EnunciateHelpers::LAMB_CLASS_AWARE.call(_oa) if _oa['@class']
@role = String.from_json(_oa) unless _oa['@class']
@end = EnunciateHelpers::LAMB_CLASS_AWARE.call(_oa) if _oa['@class']
@end = Time.from_json(_oa) unless _oa['@class']
elsif (_oa.is_a? Array)
#an array(of hashes hopefully) or scalar
@role = Array.new
@end = Array.new
_oa.each { | _item |
if ((_item.nil? || _item['@class'].nil?)rescue true)
@role.push String.from_json(_item)
@end.push Time.from_json(_item)
else
@role.push EnunciateHelpers::LAMB_CLASS_AWARE.call(_item)
@end.push EnunciateHelpers::LAMB_CLASS_AWARE.call(_item)
end
}
else
@role = _oa
@end = _oa
end
end
if !_o['stdout'].nil?
_oa = _o['stdout']
if(_oa.is_a? Hash)
@stdout = EnunciateHelpers::LAMB_CLASS_AWARE.call(_oa) if _oa['@class']
@stdout = String.from_json(_oa) unless _oa['@class']
elsif (_oa.is_a? Array)
#an array(of hashes hopefully) or scalar
@stdout = Array.new
_oa.each { | _item |
if ((_item.nil? || _item['@class'].nil?)rescue true)
@stdout.push String.from_json(_item)
else
@stdout.push EnunciateHelpers::LAMB_CLASS_AWARE.call(_item)
end
}
else
@stdout = _oa
end
end
if !_o['cmd'].nil?
_oa = _o['cmd']
if(_oa.is_a? Hash)
@cmd = EnunciateHelpers::LAMB_CLASS_AWARE.call(_oa) if _oa['@class']
@cmd = String.from_json(_oa) unless _oa['@class']
elsif (_oa.is_a? Array)
#an array(of hashes hopefully) or scalar
@cmd = Array.new
_oa.each { | _item |
if ((_item.nil? || _item['@class'].nil?)rescue true)
@cmd.push String.from_json(_item)
else
@cmd.push EnunciateHelpers::LAMB_CLASS_AWARE.call(_item)
end
}
else
@cmd = _oa
end
end
if !_o['start'].nil?
_oa = _o['start']
if(_oa.is_a? Hash)
@start = EnunciateHelpers::LAMB_CLASS_AWARE.call(_oa) if _oa['@class']
@start = Time.from_json(_oa) unless _oa['@class']
elsif (_oa.is_a? Array)
#an array(of hashes hopefully) or scalar
@start = Array.new
_oa.each { | _item |
if ((_item.nil? || _item['@class'].nil?)rescue true)
@start.push Time.from_json(_item)
else
@start.push EnunciateHelpers::LAMB_CLASS_AWARE.call(_item)
end
}
else
@start = _oa
end
end
if !_o['stderr'].nil?
_oa = _o['stderr']
if(_oa.is_a? Hash)
@stderr = EnunciateHelpers::LAMB_CLASS_AWARE.call(_oa) if _oa['@class']
@stderr = String.from_json(_oa) unless _oa['@class']
elsif (_oa.is_a? Array)
#an array(of hashes hopefully) or scalar
@stderr = Array.new
_oa.each { | _item |
if ((_item.nil? || _item['@class'].nil?)rescue true)
@stderr.push String.from_json(_item)
else
@stderr.push EnunciateHelpers::LAMB_CLASS_AWARE.call(_item)
end
}
else
@stderr = _oa
end
end
if !_o['delta'].nil?
_oa = _o['delta']
if(_oa.is_a? Hash)
@delta = EnunciateHelpers::LAMB_CLASS_AWARE.call(_oa) if _oa['@class']
@delta = Time.from_json(_oa) unless _oa['@class']
elsif (_oa.is_a? Array)
#an array(of hashes hopefully) or scalar
@delta = Array.new
_oa.each { | _item |
if ((_item.nil? || _item['@class'].nil?)rescue true)
@delta.push Time.from_json(_item)
else
@delta.push EnunciateHelpers::LAMB_CLASS_AWARE.call(_item)
end
}
else
@delta = _oa
end
end
end
# constructs a DeployParameter from a (parsed) JSON hash
# constructs a AnsibleResult from a (parsed) JSON hash
def self.from_json(o)
if o.nil?
return nil
......@@ -592,6 +590,8 @@ end
end
end
module Nl
module Uva
......@@ -1012,285 +1012,309 @@ module V1
module External
module Ansible
# (no documentation provided)
class ScaleRequest < Nl::Uva::Sne::Drip::Drip::Commons::Data::V1::External::OwnedObject
class AnsibleOutput < Nl::Uva::Sne::Drip::Drip::Commons::Data::V1::External::OwnedObject
# the scaleTargetID
attr_accessor :scaleTargetID
# the scaleTargetName
attr_accessor :scaleTargetName
# the numOfInstances
attr_accessor :numOfInstances
# the host
attr_accessor :host
# the result
attr_accessor :result
# the domain
attr_accessor :cloudDeploymentDomain
#
attr_accessor :vmType
# the provision ID
attr_accessor :provisionID
# the cloudProvider
attr_accessor :cloudProvider
# the json hash for this ScaleRequest
# the json hash for this AnsibleOutput
def to_jaxb_json_hash
_h = super
_h['scaleTargetID'] = scaleTargetID.to_jaxb_json_hash unless scaleTargetID.nil?
_h['scaleTargetName'] = scaleTargetName.to_jaxb_json_hash unless scaleTargetName.nil?
_h['numOfInstances'] = numOfInstances.to_jaxb_json_hash unless numOfInstances.nil?
_h['host'] = host.to_jaxb_json_hash unless host.nil?
_h['result'] = result.to_jaxb_json_hash unless result.nil?
_h['cloudDeploymentDomain'] = cloudDeploymentDomain.to_jaxb_json_hash unless cloudDeploymentDomain.nil?
_h['vmType'] = vmType.to_jaxb_json_hash unless vmType.nil?
_h['provisionID'] = provisionID.to_jaxb_json_hash unless provisionID.nil?
_h['cloudProvider'] = cloudProvider.to_jaxb_json_hash unless cloudProvider.nil?
return _h
end
#initializes this ScaleRequest with a json hash
#initializes this AnsibleOutput with a json hash
def init_jaxb_json_hash(_o)
super _o
if !_o['scaleTargetID'].nil?
_oa = _o['scaleTargetID']
if !_o['host'].nil?
_oa = _o['host']
if(_oa.is_a? Hash)
@scaleTargetID = EnunciateHelpers::LAMB_CLASS_AWARE.call(_oa) if _oa['@class']
@scaleTargetID = String.from_json(_oa) unless _oa['@class']
@host = EnunciateHelpers::LAMB_CLASS_AWARE.call(_oa) if _oa['@class']
@host = String.from_json(_oa) unless _oa['@class']
elsif (_oa.is_a? Array)
#an array(of hashes hopefully) or scalar
@scaleTargetID = Array.new
@host = Array.new
_oa.each { | _item |
if ((_item.nil? || _item['@class'].nil?)rescue true)
@scaleTargetID.push String.from_json(_item)
@host.push String.from_json(_item)
else
@scaleTargetID.push EnunciateHelpers::LAMB_CLASS_AWARE.call(_item)
@host.push EnunciateHelpers::LAMB_CLASS_AWARE.call(_item)
end
}
else
@scaleTargetID = _oa
@host = _oa
end
end
if !_o['scaleTargetName'].nil?
_oa = _o['scaleTargetName']
if !_o['result'].nil?
_oa = _o['result']
if(_oa.is_a? Hash)
@scaleTargetName = EnunciateHelpers::LAMB_CLASS_AWARE.call(_oa) if _oa['@class']
@scaleTargetName = String.from_json(_oa) unless _oa['@class']
@result = EnunciateHelpers::LAMB_CLASS_AWARE.call(_oa) if _oa['@class']
@result = Nl::Uva::Sne::Drip::Drip::Commons::Data::V1::External::Ansible::AnsibleResult.from_json(_oa) unless _oa['@class']
elsif (_oa.is_a? Array)
#an array(of hashes hopefully) or scalar
@scaleTargetName = Array.new
@result = Array.new
_oa.each { | _item |
if ((_item.nil? || _item['@class'].nil?)rescue true)
@scaleTargetName.push String.from_json(_item)
@result.push Nl::Uva::Sne::Drip::Drip::Commons::Data::V1::External::Ansible::AnsibleResult.from_json(_item)
else
@scaleTargetName.push EnunciateHelpers::LAMB_CLASS_AWARE.call(_item)
@result.push EnunciateHelpers::LAMB_CLASS_AWARE.call(_item)
end
}
else
@scaleTargetName = _oa
@result = _oa
end
end
if !_o['numOfInstances'].nil?
_oa = _o['numOfInstances']
if !_o['cloudDeploymentDomain'].nil?
_oa = _o['cloudDeploymentDomain']
if(_oa.is_a? Hash)
@numOfInstances = EnunciateHelpers::LAMB_CLASS_AWARE.call(_oa) if _oa['@class']
@numOfInstances = Fixnum.from_json(_oa) unless _oa['@class']
@cloudDeploymentDomain = EnunciateHelpers::LAMB_CLASS_AWARE.call(_oa) if _oa['@class']
@cloudDeploymentDomain = String.from_json(_oa) unless _oa['@class']
elsif (_oa.is_a? Array)
#an array(of hashes hopefully) or scalar
@numOfInstances = Array.new
@cloudDeploymentDomain = Array.new
_oa.each { | _item |
if ((_item.nil? || _item['@class'].nil?)rescue true)
@numOfInstances.push Fixnum.from_json(_item)
@cloudDeploymentDomain.push String.from_json(_item)
else
@numOfInstances.push EnunciateHelpers::LAMB_CLASS_AWARE.call(_item)
@cloudDeploymentDomain.push EnunciateHelpers::LAMB_CLASS_AWARE.call(_item)
end
}
else
@numOfInstances = _oa
@cloudDeploymentDomain = _oa
end
end
end
# constructs a ScaleRequest from a (parsed) JSON hash
def self.from_json(o)
if o.nil?
return nil
else
inst = new
inst.init_jaxb_json_hash o
return inst
end
end
end
end
end
end
end
end
end
end
end
end
module Nl
module Uva
module Sne
module Drip
module Drip
module Commons
module Data
module V1
module External
module Ansible
# (no documentation provided)
class BenchmarkResult < Nl::Uva::Sne::Drip::Drip::Commons::Data::V1::External::OwnedObject
# (no documentation provided)
attr_accessor :delta
# (no documentation provided)
attr_accessor :cloudDeploymentDomain
# (no documentation provided)
attr_accessor :vmType
# (no documentation provided)
attr_accessor :host
# (no documentation provided)
attr_accessor :start
# (no documentation provided)
attr_accessor :end
# the json hash for this BenchmarkResult
def to_jaxb_json_hash
_h = super
_h['delta'] = delta.to_jaxb_json_hash unless delta.nil?
_h['cloudDeploymentDomain'] = cloudDeploymentDomain.to_jaxb_json_hash unless cloudDeploymentDomain.nil?
_h['vmType'] = vmType.to_jaxb_json_hash unless vmType.nil?
_h['host'] = host.to_jaxb_json_hash unless host.nil?
_h['start'] = start.to_jaxb_json_hash unless start.nil?
_h['end'] = end.to_jaxb_json_hash unless end.nil?
return _h
end
#initializes this BenchmarkResult with a json hash
def init_jaxb_json_hash(_o)
super _o
if !_o['delta'].nil?
_oa = _o['delta']
if !_o['vmType'].nil?
_oa = _o['vmType']
if(_oa.is_a? Hash)
@delta = EnunciateHelpers::LAMB_CLASS_AWARE.call(_oa) if _oa['@class']
@delta = Time.from_json(_oa) unless _oa['@class']
@vmType = EnunciateHelpers::LAMB_CLASS_AWARE.call(_oa) if _oa['@class']
@vmType = String.from_json(_oa) unless _oa['@class']
elsif (_oa.is_a? Array)
#an array(of hashes hopefully) or scalar
@delta = Array.new
@vmType = Array.new
_oa.each { | _item |
if ((_item.nil? || _item['@class'].nil?)rescue true)
@delta.push Time.from_json(_item)
@vmType.push String.from_json(_item)
else
@delta.push EnunciateHelpers::LAMB_CLASS_AWARE.call(_item)
@vmType.push EnunciateHelpers::LAMB_CLASS_AWARE.call(_item)
end
}
else
@delta = _oa
@vmType = _oa
end
end
if !_o['cloudDeploymentDomain'].nil?
_oa = _o['cloudDeploymentDomain']
if !_o['provisionID'].nil?
_oa = _o['provisionID']
if(_oa.is_a? Hash)
@cloudDeploymentDomain = EnunciateHelpers::LAMB_CLASS_AWARE.call(_oa) if _oa['@class']
@cloudDeploymentDomain = String.from_json(_oa) unless _oa['@class']
@provisionID = EnunciateHelpers::LAMB_CLASS_AWARE.call(_oa) if _oa['@class']
@provisionID = String.from_json(_oa) unless _oa['@class']
elsif (_oa.is_a? Array)
#an array(of hashes hopefully) or scalar
@cloudDeploymentDomain = Array.new
@provisionID = Array.new
_oa.each { | _item |
if ((_item.nil? || _item['@class'].nil?)rescue true)
@cloudDeploymentDomain.push String.from_json(_item)
@provisionID.push String.from_json(_item)
else
@cloudDeploymentDomain.push EnunciateHelpers::LAMB_CLASS_AWARE.call(_item)
@provisionID.push EnunciateHelpers::LAMB_CLASS_AWARE.call(_item)
end
}
else
@cloudDeploymentDomain = _oa
@provisionID = _oa
end
end
if !_o['vmType'].nil?
_oa = _o['vmType']
if !_o['cloudProvider'].nil?
_oa = _o['cloudProvider']
if(_oa.is_a? Hash)
@vmType = EnunciateHelpers::LAMB_CLASS_AWARE.call(_oa) if _oa['@class']
@vmType = String.from_json(_oa) unless _oa['@class']
@cloudProvider = EnunciateHelpers::LAMB_CLASS_AWARE.call(_oa) if _oa['@class']
@cloudProvider = String.from_json(_oa) unless _oa['@class']
elsif (_oa.is_a? Array)
#an array(of hashes hopefully) or scalar
@vmType = Array.new
@cloudProvider = Array.new
_oa.each { | _item |
if ((_item.nil? || _item['@class'].nil?)rescue true)
@vmType.push String.from_json(_item)
@cloudProvider.push String.from_json(_item)
else
@vmType.push EnunciateHelpers::LAMB_CLASS_AWARE.call(_item)
@cloudProvider.push EnunciateHelpers::LAMB_CLASS_AWARE.call(_item)
end
}
else
@vmType = _oa
@cloudProvider = _oa
end
end
if !_o['host'].nil?
_oa = _o['host']
end
# constructs a AnsibleOutput from a (parsed) JSON hash
def self.from_json(o)
if o.nil?
return nil
else
inst = new
inst.init_jaxb_json_hash o
return inst
end
end
end
end
end
end
end
end
end
end
end
end
end
module Nl
module Uva
module Sne
module Drip
module Drip
module Commons
module Data
module V1
module External
# (no documentation provided)
class CloudCredentials < Nl::Uva::Sne::Drip::Drip::Commons::Data::V1::External::OwnedObject
# the secret key
attr_accessor :secretKey
# the cloudProviderName
attr_accessor :cloudProviderName
# the accessKeyId
attr_accessor :accessKeyId
# the attributes
attr_accessor :attributes
# the json hash for this CloudCredentials
def to_jaxb_json_hash
_h = super
_h['secretKey'] = secretKey.to_jaxb_json_hash unless secretKey.nil?
_h['cloudProviderName'] = cloudProviderName.to_jaxb_json_hash unless cloudProviderName.nil?
_h['accessKeyId'] = accessKeyId.to_jaxb_json_hash unless accessKeyId.nil?
_h['attributes'] = attributes.to_jaxb_json_hash unless attributes.nil?
return _h
end
#initializes this CloudCredentials with a json hash
def init_jaxb_json_hash(_o)
super _o
if !_o['secretKey'].nil?
_oa = _o['secretKey']
if(_oa.is_a? Hash)
@host = EnunciateHelpers::LAMB_CLASS_AWARE.call(_oa) if _oa['@class']
@host = String.from_json(_oa) unless _oa['@class']
@secretKey = EnunciateHelpers::LAMB_CLASS_AWARE.call(_oa) if _oa['@class']
@secretKey = String.from_json(_oa) unless _oa['@class']
elsif (_oa.is_a? Array)
#an array(of hashes hopefully) or scalar
@host = Array.new
@secretKey = Array.new
_oa.each { | _item |
if ((_item.nil? || _item['@class'].nil?)rescue true)
@host.push String.from_json(_item)
@secretKey.push String.from_json(_item)
else
@host.push EnunciateHelpers::LAMB_CLASS_AWARE.call(_item)
@secretKey.push EnunciateHelpers::LAMB_CLASS_AWARE.call(_item)
end
}
else
@host = _oa
@secretKey = _oa
end
end
if !_o['start'].nil?
_oa = _o['start']
if !_o['cloudProviderName'].nil?
_oa = _o['cloudProviderName']
if(_oa.is_a? Hash)
@start = EnunciateHelpers::LAMB_CLASS_AWARE.call(_oa) if _oa['@class']
@start = Time.from_json(_oa) unless _oa['@class']
@cloudProviderName = EnunciateHelpers::LAMB_CLASS_AWARE.call(_oa) if _oa['@class']
@cloudProviderName = String.from_json(_oa) unless _oa['@class']
elsif (_oa.is_a? Array)
#an array(of hashes hopefully) or scalar
@start = Array.new
@cloudProviderName = Array.new
_oa.each { | _item |
if ((_item.nil? || _item['@class'].nil?)rescue true)
@start.push Time.from_json(_item)
@cloudProviderName.push String.from_json(_item)
else
@start.push EnunciateHelpers::LAMB_CLASS_AWARE.call(_item)
@cloudProviderName.push EnunciateHelpers::LAMB_CLASS_AWARE.call(_item)
end
}
else
@start = _oa
@cloudProviderName = _oa
end
end
if !_o['end'].nil?
_oa = _o['end']
if !_o['accessKeyId'].nil?
_oa = _o['accessKeyId']
if(_oa.is_a? Hash)
@end = EnunciateHelpers::LAMB_CLASS_AWARE.call(_oa) if _oa['@class']
@end = Time.from_json(_oa) unless _oa['@class']
@accessKeyId = EnunciateHelpers::LAMB_CLASS_AWARE.call(_oa) if _oa['@class']
@accessKeyId = String.from_json(_oa) unless _oa['@class']
elsif (_oa.is_a? Array)
#an array(of hashes hopefully) or scalar
@end = Array.new
@accessKeyId = Array.new
_oa.each { | _item |
if ((_item.nil? || _item['@class'].nil?)rescue true)
@end.push Time.from_json(_item)
@accessKeyId.push String.from_json(_item)
else
@end.push EnunciateHelpers::LAMB_CLASS_AWARE.call(_item)
@accessKeyId.push EnunciateHelpers::LAMB_CLASS_AWARE.call(_item)
end
}
else
@end = _oa
@accessKeyId = _oa
end
end
if !_o['attributes'].nil?
_oa = _o['attributes']
if(_oa.is_a? Hash)
@attributes = EnunciateHelpers::LAMB_CLASS_AWARE.call(_oa) if _oa['@class']
@attributes = Hash.from_json(_oa) unless _oa['@class']
elsif (_oa.is_a? Array)
#an array(of hashes hopefully) or scalar
@attributes = Array.new
_oa.each { | _item |
if ((_item.nil? || _item['@class'].nil?)rescue true)
@attributes.push Hash.from_json(_item)
else
@attributes.push EnunciateHelpers::LAMB_CLASS_AWARE.call(_item)
end
}
else
@attributes = _oa
end
end
end
# constructs a BenchmarkResult from a (parsed) JSON hash
# constructs a CloudCredentials from a (parsed) JSON hash
def self.from_json(o)
if o.nil?
return nil
......@@ -1320,8 +1344,6 @@ end
end
end
module Nl
module Uva
......@@ -1711,24 +1733,153 @@ module V1
module External
# (no documentation provided)
class MonitorringMessage < Nl::Uva::Sne::Drip::Drip::Commons::Data::V1::External::OwnedObject
# the metricMame
attr_accessor :metricMame
# the subid
attr_accessor :subid
# the value
attr_accessor :value
# the messageType
attr_accessor :messageType
# the date
attr_accessor :date
# the time
attr_accessor :time
class DeployRequest < Nl::Uva::Sne::Drip::Drip::Commons::Data::V1::External::OwnedObject
# the json hash for this MonitorringMessage
def to_jaxb_json_hash
_h = super
# the provisionID
attr_accessor :provisionID
# the managerType
attr_accessor :managerType
# the configurationID
attr_accessor :configurationID
# the json hash for this DeployRequest
def to_jaxb_json_hash
_h = super
_h['provisionID'] = provisionID.to_jaxb_json_hash unless provisionID.nil?
_h['managerType'] = managerType.to_jaxb_json_hash unless managerType.nil?
_h['configurationID'] = configurationID.to_jaxb_json_hash unless configurationID.nil?
return _h
end
#initializes this DeployRequest with a json hash
def init_jaxb_json_hash(_o)
super _o
if !_o['provisionID'].nil?
_oa = _o['provisionID']
if(_oa.is_a? Hash)
@provisionID = EnunciateHelpers::LAMB_CLASS_AWARE.call(_oa) if _oa['@class']
@provisionID = String.from_json(_oa) unless _oa['@class']
elsif (_oa.is_a? Array)
#an array(of hashes hopefully) or scalar
@provisionID = Array.new
_oa.each { | _item |
if ((_item.nil? || _item['@class'].nil?)rescue true)
@provisionID.push String.from_json(_item)
else
@provisionID.push EnunciateHelpers::LAMB_CLASS_AWARE.call(_item)
end
}
else
@provisionID = _oa
end
end
if !_o['managerType'].nil?
_oa = _o['managerType']
if(_oa.is_a? Hash)
@managerType = EnunciateHelpers::LAMB_CLASS_AWARE.call(_oa) if _oa['@class']
@managerType = String.from_json(_oa) unless _oa['@class']
elsif (_oa.is_a? Array)
#an array(of hashes hopefully) or scalar
@managerType = Array.new
_oa.each { | _item |
if ((_item.nil? || _item['@class'].nil?)rescue true)
@managerType.push String.from_json(_item)
else
@managerType.push EnunciateHelpers::LAMB_CLASS_AWARE.call(_item)
end
}
else
@managerType = _oa
end
end
if !_o['configurationID'].nil?
_oa = _o['configurationID']
if(_oa.is_a? Hash)
@configurationID = EnunciateHelpers::LAMB_CLASS_AWARE.call(_oa) if _oa['@class']
@configurationID = String.from_json(_oa) unless _oa['@class']
elsif (_oa.is_a? Array)
#an array(of hashes hopefully) or scalar
@configurationID = Array.new
_oa.each { | _item |
if ((_item.nil? || _item['@class'].nil?)rescue true)
@configurationID.push String.from_json(_item)
else
@configurationID.push EnunciateHelpers::LAMB_CLASS_AWARE.call(_item)
end
}
else
@configurationID = _oa
end
end
end
# constructs a DeployRequest from a (parsed) JSON hash
def self.from_json(o)
if o.nil?
return nil
else
inst = new
inst.init_jaxb_json_hash o
return inst
end
end
end
end
end
end
end
end
end
end
end
end
module Nl
module Uva
module Sne
module Drip
module Drip
module Commons
module Data
module V1
module External
# (no documentation provided)
class MonitorringMessage < Nl::Uva::Sne::Drip::Drip::Commons::Data::V1::External::OwnedObject
# the metricMame
attr_accessor :metricMame
# the subid
attr_accessor :subid
# the value
attr_accessor :value
# the messageType
attr_accessor :messageType
# the date
attr_accessor :date
# the time
attr_accessor :time
# the json hash for this MonitorringMessage
def to_jaxb_json_hash
_h = super
_h['metricMame'] = metricMame.to_jaxb_json_hash unless metricMame.nil?
_h['subid'] = subid.to_jaxb_json_hash unless subid.nil?
_h['value'] = value.to_jaxb_json_hash unless value.nil?
......@@ -1906,87 +2057,43 @@ module V1
module External
# (no documentation provided)
class DeployRequest < Nl::Uva::Sne::Drip::Drip::Commons::Data::V1::External::OwnedObject
class KeyValueHolder < Nl::Uva::Sne::Drip::Drip::Commons::Data::V1::External::OwnedObject
# the provisionID
attr_accessor :provisionID
# the managerType
attr_accessor :managerType
# the configurationID
attr_accessor :configurationID
# the keyValue
attr_accessor :keyValue
# the json hash for this DeployRequest
# the json hash for this KeyValueHolder
def to_jaxb_json_hash
_h = super
_h['provisionID'] = provisionID.to_jaxb_json_hash unless provisionID.nil?
_h['managerType'] = managerType.to_jaxb_json_hash unless managerType.nil?
_h['configurationID'] = configurationID.to_jaxb_json_hash unless configurationID.nil?
_h['keyValue'] = keyValue.to_jaxb_json_hash unless keyValue.nil?
return _h
end
#initializes this DeployRequest with a json hash
#initializes this KeyValueHolder with a json hash
def init_jaxb_json_hash(_o)
super _o
if !_o['provisionID'].nil?
_oa = _o['provisionID']
if(_oa.is_a? Hash)
@provisionID = EnunciateHelpers::LAMB_CLASS_AWARE.call(_oa) if _oa['@class']
@provisionID = String.from_json(_oa) unless _oa['@class']
elsif (_oa.is_a? Array)
#an array(of hashes hopefully) or scalar
@provisionID = Array.new
_oa.each { | _item |
if ((_item.nil? || _item['@class'].nil?)rescue true)
@provisionID.push String.from_json(_item)
else
@provisionID.push EnunciateHelpers::LAMB_CLASS_AWARE.call(_item)
end
}
else
@provisionID = _oa
end
end
if !_o['managerType'].nil?
_oa = _o['managerType']
if(_oa.is_a? Hash)
@managerType = EnunciateHelpers::LAMB_CLASS_AWARE.call(_oa) if _oa['@class']
@managerType = String.from_json(_oa) unless _oa['@class']
elsif (_oa.is_a? Array)
#an array(of hashes hopefully) or scalar
@managerType = Array.new
_oa.each { | _item |
if ((_item.nil? || _item['@class'].nil?)rescue true)
@managerType.push String.from_json(_item)
else
@managerType.push EnunciateHelpers::LAMB_CLASS_AWARE.call(_item)
end
}
else
@managerType = _oa
end
end
if !_o['configurationID'].nil?
_oa = _o['configurationID']
if !_o['keyValue'].nil?
_oa = _o['keyValue']
if(_oa.is_a? Hash)
@configurationID = EnunciateHelpers::LAMB_CLASS_AWARE.call(_oa) if _oa['@class']
@configurationID = String.from_json(_oa) unless _oa['@class']
@keyValue = EnunciateHelpers::LAMB_CLASS_AWARE.call(_oa) if _oa['@class']
@keyValue = Hash.from_json(_oa) unless _oa['@class']
elsif (_oa.is_a? Array)
#an array(of hashes hopefully) or scalar
@configurationID = Array.new
@keyValue = Array.new
_oa.each { | _item |
if ((_item.nil? || _item['@class'].nil?)rescue true)
@configurationID.push String.from_json(_item)
@keyValue.push Hash.from_json(_item)
else
@configurationID.push EnunciateHelpers::LAMB_CLASS_AWARE.call(_item)
@keyValue.push EnunciateHelpers::LAMB_CLASS_AWARE.call(_item)
end
}
else
@configurationID = _oa
@keyValue = _oa
end
end
end
# constructs a DeployRequest from a (parsed) JSON hash
# constructs a KeyValueHolder from a (parsed) JSON hash
def self.from_json(o)
if o.nil?
return nil
......@@ -2034,195 +2141,156 @@ module V1
module External
module Ansible
# (no documentation provided)
class KeyValueHolder < Nl::Uva::Sne::Drip::Drip::Commons::Data::V1::External::OwnedObject
class BenchmarkResult < Nl::Uva::Sne::Drip::Drip::Commons::Data::V1::External::OwnedObject
# the keyValue
attr_accessor :keyValue
# (no documentation provided)
attr_accessor :host
# (no documentation provided)
attr_accessor :vmType
# (no documentation provided)
attr_accessor :end
# (no documentation provided)
attr_accessor :cloudDeploymentDomain
# (no documentation provided)
attr_accessor :delta
# (no documentation provided)
attr_accessor :start
# the json hash for this KeyValueHolder
# the json hash for this BenchmarkResult
def to_jaxb_json_hash
_h = super
_h['keyValue'] = keyValue.to_jaxb_json_hash unless keyValue.nil?
_h['host'] = host.to_jaxb_json_hash unless host.nil?
_h['vmType'] = vmType.to_jaxb_json_hash unless vmType.nil?
_h['end'] = end.to_jaxb_json_hash unless end.nil?
_h['cloudDeploymentDomain'] = cloudDeploymentDomain.to_jaxb_json_hash unless cloudDeploymentDomain.nil?
_h['delta'] = delta.to_jaxb_json_hash unless delta.nil?
_h['start'] = start.to_jaxb_json_hash unless start.nil?
return _h
end
#initializes this KeyValueHolder with a json hash
#initializes this BenchmarkResult with a json hash
def init_jaxb_json_hash(_o)
super _o
if !_o['keyValue'].nil?
_oa = _o['keyValue']
if !_o['host'].nil?
_oa = _o['host']
if(_oa.is_a? Hash)
@keyValue = EnunciateHelpers::LAMB_CLASS_AWARE.call(_oa) if _oa['@class']
@keyValue = Hash.from_json(_oa) unless _oa['@class']
@host = EnunciateHelpers::LAMB_CLASS_AWARE.call(_oa) if _oa['@class']
@host = String.from_json(_oa) unless _oa['@class']
elsif (_oa.is_a? Array)
#an array(of hashes hopefully) or scalar
@keyValue = Array.new
@host = Array.new
_oa.each { | _item |
if ((_item.nil? || _item['@class'].nil?)rescue true)
@keyValue.push Hash.from_json(_item)
@host.push String.from_json(_item)
else
@keyValue.push EnunciateHelpers::LAMB_CLASS_AWARE.call(_item)
@host.push EnunciateHelpers::LAMB_CLASS_AWARE.call(_item)
end
}
else
@keyValue = _oa
@host = _oa
end
end
end
# constructs a KeyValueHolder from a (parsed) JSON hash
def self.from_json(o)
if o.nil?
return nil
else
inst = new
inst.init_jaxb_json_hash o
return inst
end
end
end
end
end
end
end
end
end
end
end
end
module Nl
module Uva
module Sne
module Drip
module Drip
module Commons
module Data
module V1
module External
# (no documentation provided)
class CloudCredentials < Nl::Uva::Sne::Drip::Drip::Commons::Data::V1::External::OwnedObject
# the secret key
attr_accessor :secretKey
# the cloudProviderName
attr_accessor :cloudProviderName
# the accessKeyId
attr_accessor :accessKeyId
# the attributes
attr_accessor :attributes
# the json hash for this CloudCredentials
def to_jaxb_json_hash
_h = super
_h['secretKey'] = secretKey.to_jaxb_json_hash unless secretKey.nil?
_h['cloudProviderName'] = cloudProviderName.to_jaxb_json_hash unless cloudProviderName.nil?
_h['accessKeyId'] = accessKeyId.to_jaxb_json_hash unless accessKeyId.nil?
_h['attributes'] = attributes.to_jaxb_json_hash unless attributes.nil?
return _h
end
#initializes this CloudCredentials with a json hash
def init_jaxb_json_hash(_o)
super _o
if !_o['secretKey'].nil?
_oa = _o['secretKey']
if !_o['vmType'].nil?
_oa = _o['vmType']
if(_oa.is_a? Hash)
@secretKey = EnunciateHelpers::LAMB_CLASS_AWARE.call(_oa) if _oa['@class']
@secretKey = String.from_json(_oa) unless _oa['@class']
@vmType = EnunciateHelpers::LAMB_CLASS_AWARE.call(_oa) if _oa['@class']
@vmType = String.from_json(_oa) unless _oa['@class']
elsif (_oa.is_a? Array)
#an array(of hashes hopefully) or scalar
@secretKey = Array.new
@vmType = Array.new
_oa.each { | _item |
if ((_item.nil? || _item['@class'].nil?)rescue true)
@secretKey.push String.from_json(_item)
@vmType.push String.from_json(_item)
else
@secretKey.push EnunciateHelpers::LAMB_CLASS_AWARE.call(_item)
@vmType.push EnunciateHelpers::LAMB_CLASS_AWARE.call(_item)
end
}
else
@secretKey = _oa
@vmType = _oa
end
end
if !_o['cloudProviderName'].nil?
_oa = _o['cloudProviderName']
if !_o['end'].nil?
_oa = _o['end']
if(_oa.is_a? Hash)
@cloudProviderName = EnunciateHelpers::LAMB_CLASS_AWARE.call(_oa) if _oa['@class']
@cloudProviderName = String.from_json(_oa) unless _oa['@class']
@end = EnunciateHelpers::LAMB_CLASS_AWARE.call(_oa) if _oa['@class']
@end = Time.from_json(_oa) unless _oa['@class']
elsif (_oa.is_a? Array)
#an array(of hashes hopefully) or scalar
@cloudProviderName = Array.new
@end = Array.new
_oa.each { | _item |
if ((_item.nil? || _item['@class'].nil?)rescue true)
@cloudProviderName.push String.from_json(_item)
@end.push Time.from_json(_item)
else
@cloudProviderName.push EnunciateHelpers::LAMB_CLASS_AWARE.call(_item)
@end.push EnunciateHelpers::LAMB_CLASS_AWARE.call(_item)
end
}
else
@cloudProviderName = _oa
@end = _oa
end
end
if !_o['accessKeyId'].nil?
_oa = _o['accessKeyId']
if !_o['cloudDeploymentDomain'].nil?
_oa = _o['cloudDeploymentDomain']
if(_oa.is_a? Hash)
@accessKeyId = EnunciateHelpers::LAMB_CLASS_AWARE.call(_oa) if _oa['@class']
@accessKeyId = String.from_json(_oa) unless _oa['@class']
@cloudDeploymentDomain = EnunciateHelpers::LAMB_CLASS_AWARE.call(_oa) if _oa['@class']
@cloudDeploymentDomain = String.from_json(_oa) unless _oa['@class']
elsif (_oa.is_a? Array)
#an array(of hashes hopefully) or scalar
@accessKeyId = Array.new
@cloudDeploymentDomain = Array.new
_oa.each { | _item |
if ((_item.nil? || _item['@class'].nil?)rescue true)
@accessKeyId.push String.from_json(_item)
@cloudDeploymentDomain.push String.from_json(_item)
else
@accessKeyId.push EnunciateHelpers::LAMB_CLASS_AWARE.call(_item)
@cloudDeploymentDomain.push EnunciateHelpers::LAMB_CLASS_AWARE.call(_item)
end
}
else
@accessKeyId = _oa
@cloudDeploymentDomain = _oa
end
end
if !_o['attributes'].nil?
_oa = _o['attributes']
if !_o['delta'].nil?
_oa = _o['delta']
if(_oa.is_a? Hash)
@attributes = EnunciateHelpers::LAMB_CLASS_AWARE.call(_oa) if _oa['@class']
@attributes = Hash.from_json(_oa) unless _oa['@class']
@delta = EnunciateHelpers::LAMB_CLASS_AWARE.call(_oa) if _oa['@class']
@delta = Time.from_json(_oa) unless _oa['@class']
elsif (_oa.is_a? Array)
#an array(of hashes hopefully) or scalar
@attributes = Array.new
@delta = Array.new
_oa.each { | _item |
if ((_item.nil? || _item['@class'].nil?)rescue true)
@attributes.push Hash.from_json(_item)
@delta.push Time.from_json(_item)
else
@attributes.push EnunciateHelpers::LAMB_CLASS_AWARE.call(_item)
@delta.push EnunciateHelpers::LAMB_CLASS_AWARE.call(_item)
end
}
else
@attributes = _oa
@delta = _oa
end
end
if !_o['start'].nil?
_oa = _o['start']
if(_oa.is_a? Hash)
@start = EnunciateHelpers::LAMB_CLASS_AWARE.call(_oa) if _oa['@class']
@start = Time.from_json(_oa) unless _oa['@class']
elsif (_oa.is_a? Array)
#an array(of hashes hopefully) or scalar
@start = Array.new
_oa.each { | _item |
if ((_item.nil? || _item['@class'].nil?)rescue true)
@start.push Time.from_json(_item)
else
@start.push EnunciateHelpers::LAMB_CLASS_AWARE.call(_item)
end
}
else
@start = _oa
end
end
end
# constructs a CloudCredentials from a (parsed) JSON hash
# constructs a BenchmarkResult from a (parsed) JSON hash
def self.from_json(o)
if o.nil?
return nil
......@@ -2252,6 +2320,8 @@ end
end
end
module Nl
module Uva
......@@ -2270,156 +2340,88 @@ module V1
module External
module Ansible
# (no documentation provided)
class AnsibleOutput < Nl::Uva::Sne::Drip::Drip::Commons::Data::V1::External::OwnedObject
class ScaleRequest < Nl::Uva::Sne::Drip::Drip::Commons::Data::V1::External::OwnedObject
# the host
attr_accessor :host
# the result
attr_accessor :result
# the domain
attr_accessor :cloudDeploymentDomain
#
attr_accessor :vmType
# the provision ID
attr_accessor :provisionID
# the cloudProvider
attr_accessor :cloudProvider
# the scaleTargetID
attr_accessor :scaleTargetID
# the scaleTargetName
attr_accessor :scaleTargetName
# the numOfInstances
attr_accessor :numOfInstances
# the json hash for this AnsibleOutput
# the json hash for this ScaleRequest
def to_jaxb_json_hash
_h = super
_h['host'] = host.to_jaxb_json_hash unless host.nil?
_h['result'] = result.to_jaxb_json_hash unless result.nil?
_h['cloudDeploymentDomain'] = cloudDeploymentDomain.to_jaxb_json_hash unless cloudDeploymentDomain.nil?
_h['vmType'] = vmType.to_jaxb_json_hash unless vmType.nil?
_h['provisionID'] = provisionID.to_jaxb_json_hash unless provisionID.nil?
_h['cloudProvider'] = cloudProvider.to_jaxb_json_hash unless cloudProvider.nil?
_h['scaleTargetID'] = scaleTargetID.to_jaxb_json_hash unless scaleTargetID.nil?
_h['scaleTargetName'] = scaleTargetName.to_jaxb_json_hash unless scaleTargetName.nil?
_h['numOfInstances'] = numOfInstances.to_jaxb_json_hash unless numOfInstances.nil?
return _h
end
#initializes this AnsibleOutput with a json hash
#initializes this ScaleRequest with a json hash
def init_jaxb_json_hash(_o)
super _o
if !_o['host'].nil?
_oa = _o['host']
if(_oa.is_a? Hash)
@host = EnunciateHelpers::LAMB_CLASS_AWARE.call(_oa) if _oa['@class']
@host = String.from_json(_oa) unless _oa['@class']
elsif (_oa.is_a? Array)
#an array(of hashes hopefully) or scalar
@host = Array.new
_oa.each { | _item |
if ((_item.nil? || _item['@class'].nil?)rescue true)
@host.push String.from_json(_item)
else
@host.push EnunciateHelpers::LAMB_CLASS_AWARE.call(_item)
end
}
else
@host = _oa
end
end
if !_o['result'].nil?
_oa = _o['result']
if(_oa.is_a? Hash)
@result = EnunciateHelpers::LAMB_CLASS_AWARE.call(_oa) if _oa['@class']
@result = Nl::Uva::Sne::Drip::Drip::Commons::Data::V1::External::Ansible::AnsibleResult.from_json(_oa) unless _oa['@class']
elsif (_oa.is_a? Array)
#an array(of hashes hopefully) or scalar
@result = Array.new
_oa.each { | _item |
if ((_item.nil? || _item['@class'].nil?)rescue true)
@result.push Nl::Uva::Sne::Drip::Drip::Commons::Data::V1::External::Ansible::AnsibleResult.from_json(_item)
else
@result.push EnunciateHelpers::LAMB_CLASS_AWARE.call(_item)
end
}
else
@result = _oa
end
end
if !_o['cloudDeploymentDomain'].nil?
_oa = _o['cloudDeploymentDomain']
if(_oa.is_a? Hash)
@cloudDeploymentDomain = EnunciateHelpers::LAMB_CLASS_AWARE.call(_oa) if _oa['@class']
@cloudDeploymentDomain = String.from_json(_oa) unless _oa['@class']
elsif (_oa.is_a? Array)
#an array(of hashes hopefully) or scalar
@cloudDeploymentDomain = Array.new
_oa.each { | _item |
if ((_item.nil? || _item['@class'].nil?)rescue true)
@cloudDeploymentDomain.push String.from_json(_item)
else
@cloudDeploymentDomain.push EnunciateHelpers::LAMB_CLASS_AWARE.call(_item)
end
}
else
@cloudDeploymentDomain = _oa
end
end
if !_o['vmType'].nil?
_oa = _o['vmType']
if !_o['scaleTargetID'].nil?
_oa = _o['scaleTargetID']
if(_oa.is_a? Hash)
@vmType = EnunciateHelpers::LAMB_CLASS_AWARE.call(_oa) if _oa['@class']
@vmType = String.from_json(_oa) unless _oa['@class']
@scaleTargetID = EnunciateHelpers::LAMB_CLASS_AWARE.call(_oa) if _oa['@class']
@scaleTargetID = String.from_json(_oa) unless _oa['@class']
elsif (_oa.is_a? Array)
#an array(of hashes hopefully) or scalar
@vmType = Array.new
@scaleTargetID = Array.new
_oa.each { | _item |
if ((_item.nil? || _item['@class'].nil?)rescue true)
@vmType.push String.from_json(_item)
@scaleTargetID.push String.from_json(_item)
else
@vmType.push EnunciateHelpers::LAMB_CLASS_AWARE.call(_item)
@scaleTargetID.push EnunciateHelpers::LAMB_CLASS_AWARE.call(_item)
end
}
else
@vmType = _oa
@scaleTargetID = _oa
end
end
if !_o['provisionID'].nil?
_oa = _o['provisionID']
if !_o['scaleTargetName'].nil?
_oa = _o['scaleTargetName']
if(_oa.is_a? Hash)
@provisionID = EnunciateHelpers::LAMB_CLASS_AWARE.call(_oa) if _oa['@class']
@provisionID = String.from_json(_oa) unless _oa['@class']
@scaleTargetName = EnunciateHelpers::LAMB_CLASS_AWARE.call(_oa) if _oa['@class']
@scaleTargetName = String.from_json(_oa) unless _oa['@class']
elsif (_oa.is_a? Array)
#an array(of hashes hopefully) or scalar
@provisionID = Array.new
@scaleTargetName = Array.new
_oa.each { | _item |
if ((_item.nil? || _item['@class'].nil?)rescue true)
@provisionID.push String.from_json(_item)
@scaleTargetName.push String.from_json(_item)
else
@provisionID.push EnunciateHelpers::LAMB_CLASS_AWARE.call(_item)
@scaleTargetName.push EnunciateHelpers::LAMB_CLASS_AWARE.call(_item)
end
}
else
@provisionID = _oa
@scaleTargetName = _oa
end
end
if !_o['cloudProvider'].nil?
_oa = _o['cloudProvider']
if !_o['numOfInstances'].nil?
_oa = _o['numOfInstances']
if(_oa.is_a? Hash)
@cloudProvider = EnunciateHelpers::LAMB_CLASS_AWARE.call(_oa) if _oa['@class']
@cloudProvider = String.from_json(_oa) unless _oa['@class']
@numOfInstances = EnunciateHelpers::LAMB_CLASS_AWARE.call(_oa) if _oa['@class']
@numOfInstances = Fixnum.from_json(_oa) unless _oa['@class']
elsif (_oa.is_a? Array)
#an array(of hashes hopefully) or scalar
@cloudProvider = Array.new
@numOfInstances = Array.new
_oa.each { | _item |
if ((_item.nil? || _item['@class'].nil?)rescue true)
@cloudProvider.push String.from_json(_item)
@numOfInstances.push Fixnum.from_json(_item)
else
@cloudProvider.push EnunciateHelpers::LAMB_CLASS_AWARE.call(_item)
@numOfInstances.push EnunciateHelpers::LAMB_CLASS_AWARE.call(_item)
end
}
else
@cloudProvider = _oa
@numOfInstances = _oa
end
end
end
# constructs a AnsibleOutput from a (parsed) JSON hash
# constructs a ScaleRequest from a (parsed) JSON hash
def self.from_json(o)
if o.nil?
return nil
......@@ -2449,8 +2451,6 @@ end
end
end
module Nl
module Uva
......
......@@ -90,7 +90,7 @@ class</p>
</td>
</tr>
<tr>
<td> <span class="property-name">start</span>
<td> <span class="property-name">end</span>
</td>
<td> <span class="datatype-reference">number
</span>
......@@ -99,9 +99,9 @@ class</p>
</td>
</tr>
<tr>
<td> <span class="property-name">cloudDeploymentDomain</span>
<td> <span class="property-name">start</span>
</td>
<td> <span class="datatype-reference">string
<td> <span class="datatype-reference">number
</span>
</td>
<td> <span class="property-description"></span>
......@@ -126,9 +126,9 @@ class</p>
</td>
</tr>
<tr>
<td> <span class="property-name">end</span>
<td> <span class="property-name">cloudDeploymentDomain</span>
</td>
<td> <span class="datatype-reference">number
<td> <span class="datatype-reference">string
</span>
</td>
<td> <span class="property-description"></span>
......@@ -168,11 +168,11 @@ No need to set during a POST</span></td>
<pre class="prettyprint language-js example">{
&quot;host&quot; : &quot;147.228.242.58&quot;,
&quot;end&quot; : 12345,
&quot;start&quot; : 12345,
&quot;cloudDeploymentDomain&quot; : &quot;us-east-1&quot;,
&quot;delta&quot; : 12345,
&quot;vmType&quot; : &quot;...&quot;,
&quot;end&quot; : 12345,
&quot;cloudDeploymentDomain&quot; : &quot;us-east-1&quot;,
&quot;owner&quot; : &quot;user1&quot;,
&quot;id&quot; : &quot;58e3946e0fb4f562d84ba1ad&quot;,
&quot;timestamp&quot; : 1499793079011
......
......@@ -69,7 +69,7 @@ class</p>
<dl class="dl-horizontal">
<dt>Subtypes</dt>
<dd><a href="json_KeyPair.html">KeyPair</a>, <a href="json_ScaleRequest.html">ScaleRequest</a>, <a href="json_AnsibleOutput.html">AnsibleOutput</a>, <a href="json_CloudCredentials.html">CloudCredentials</a>, <a href="json_BenchmarkResult.html">BenchmarkResult</a>, <a href="json_DeployResponse.html">DeployResponse</a>, <a href="json_DRIPLogRecord.html">DRIPLogRecord</a>, <a href="json_ProvisionRequest.html">ProvisionRequest</a>, <a href="json_Script.html">Script</a>, <a href="json_KeyValueHolder.html">KeyValueHolder</a>, <a href="json_DeployRequest.html">DeployRequest</a>, <a href="json_ProvisionResponse.html">ProvisionResponse</a>, <a href="json_MonitorringMessage.html">MonitorringMessage</a></dd>
<dd><a href="json_KeyPair.html">KeyPair</a>, <a href="json_ScaleRequest.html">ScaleRequest</a>, <a href="json_AnsibleOutput.html">AnsibleOutput</a>, <a href="json_BenchmarkResult.html">BenchmarkResult</a>, <a href="json_CloudCredentials.html">CloudCredentials</a>, <a href="json_DeployResponse.html">DeployResponse</a>, <a href="json_DRIPLogRecord.html">DRIPLogRecord</a>, <a href="json_ProvisionRequest.html">ProvisionRequest</a>, <a href="json_Script.html">Script</a>, <a href="json_KeyValueHolder.html">KeyValueHolder</a>, <a href="json_DeployRequest.html">DeployRequest</a>, <a href="json_MonitorringMessage.html">MonitorringMessage</a>, <a href="json_ProvisionResponse.html">ProvisionResponse</a></dd>
</dl>
<table class="table datatype-properties">
......
......@@ -821,15 +821,15 @@ class]]>
<xs:complexContent>
<xs:extension base="ownedObject">
<xs:sequence>
<xs:element name="start" type="xs:dateTime" minOccurs="0">
</xs:element>
<xs:element name="cloudDeploymentDomain" type="xs:string" minOccurs="0">
<xs:element name="delta" type="xs:dateTime" minOccurs="0">
</xs:element>
<xs:element name="host" type="xs:string" minOccurs="0">
</xs:element>
<xs:element name="end" type="xs:dateTime" minOccurs="0">
</xs:element>
<xs:element name="delta" type="xs:dateTime" minOccurs="0">
<xs:element name="cloudDeploymentDomain" type="xs:string" minOccurs="0">
</xs:element>
<xs:element name="start" type="xs:dateTime" minOccurs="0">
</xs:element>
<xs:element name="vmType" type="xs:string" minOccurs="0">
</xs:element>
......
......@@ -145,11 +145,11 @@ Content-Type: application/json
<code class="prettyprint language-js">
[ {
&quot;host&quot; : &quot;147.228.242.58&quot;,
&quot;end&quot; : 12345,
&quot;start&quot; : 12345,
&quot;cloudDeploymentDomain&quot; : &quot;us-east-1&quot;,
&quot;delta&quot; : 12345,
&quot;vmType&quot; : &quot;...&quot;,
&quot;end&quot; : 12345,
&quot;cloudDeploymentDomain&quot; : &quot;us-east-1&quot;,
&quot;owner&quot; : &quot;user1&quot;,
&quot;id&quot; : &quot;58e3946e0fb4f562d84ba1ad&quot;,
&quot;timestamp&quot; : 1499793079011
......@@ -515,11 +515,11 @@ Content-Type: application/json
<code class="prettyprint language-js">
{
&quot;host&quot; : &quot;147.228.242.58&quot;,
&quot;end&quot; : 12345,
&quot;start&quot; : 12345,
&quot;cloudDeploymentDomain&quot; : &quot;us-east-1&quot;,
&quot;delta&quot; : 12345,
&quot;vmType&quot; : &quot;...&quot;,
&quot;end&quot; : 12345,
&quot;cloudDeploymentDomain&quot; : &quot;us-east-1&quot;,
&quot;owner&quot; : &quot;user1&quot;,
&quot;id&quot; : &quot;58e3946e0fb4f562d84ba1ad&quot;,
&quot;timestamp&quot; : 1499793079011
......
......@@ -220,11 +220,11 @@ It is created automatically. No need to set during a POST</span></td>
<p class="lead">Example</p>
<pre class="prettyprint language-xml example">&lt;b-----&gt;
&lt;start&gt;...&lt;/start&gt;
&lt;cloudDeploymentDomain&gt;us-east-1&lt;/cloudDeploymentDomain&gt;
&lt;delta&gt;...&lt;/delta&gt;
&lt;host&gt;147.228.242.58&lt;/host&gt;
&lt;end&gt;...&lt;/end&gt;
&lt;delta&gt;...&lt;/delta&gt;
&lt;cloudDeploymentDomain&gt;us-east-1&lt;/cloudDeploymentDomain&gt;
&lt;start&gt;...&lt;/start&gt;
&lt;vmType&gt;...&lt;/vmType&gt;
&lt;owner&gt;user1&lt;/owner&gt;
&lt;/b-----&gt;
......
......@@ -72,7 +72,7 @@
<h1 class="page-header">Files and Libraries</h1>
<h3 id="artifact_gwt_json_overlay">GWT JSON Overlay</h3>
<p class="lead">Created November 21, 2017</p>
<p class="lead">Created November 22, 2017</p>
<p> <p>
The <a href="http://code.google.com/webtoolkit/">Google Web Toolkit</a> JSON Overlay library provides the JSON Overlays that
can be used to access the Web service API for this application.
......@@ -97,7 +97,7 @@
</tbody>
</table>
<h3 id="artifact_java_json_client_library">Java JSON Client Library</h3>
<p class="lead">Created November 21, 2017</p>
<p class="lead">Created November 22, 2017</p>
<p><p>
The Java client-side library is used to provide the set of Java objects that can be serialized
to/from JSON using <a href="http://jackson.codehaus.org/">Jackson</a>. This is useful for accessing the
......@@ -127,7 +127,7 @@
</tbody>
</table>
<h3 id="artifact_java_xml_client_library">Java XML Client Library</h3>
<p class="lead">Created November 21, 2017</p>
<p class="lead">Created November 22, 2017</p>
<p><p>
The Java client-side library is used to access the Web service API for this application using Java.
</p>
......@@ -155,7 +155,7 @@
</tbody>
</table>
<h3 id="artifact_js_client_library">JavaScript Client Library</h3>
<p class="lead">Created November 21, 2017</p>
<p class="lead">Created November 22, 2017</p>
<p><p>
The JavaScript client-side library defines classes that can be (de)serialized to/from JSON.
This is useful for accessing the resources that are published by this application, but only
......@@ -184,13 +184,13 @@
<tbody data-link="row" class="rowlink">
<tr class="clickable-row" data-href="drip-api-js.zip">
<td><span class="downloadfile-name">drip-api-js.zip</span></td>
<td><span class="downloadfile-size">5.91K</span></td>
<td><span class="downloadfile-size">5.92K</span></td>
<td><span class="downloadfile-description">&nbsp;</span></td>
</tr>
</tbody>
</table>
<h3 id="artifact_php_json_client_library">PHP JSON Client Library</h3>
<p class="lead">Created November 21, 2017</p>
<p class="lead">Created November 22, 2017</p>
<p><p>
The PHP JSON client-side library defines the PHP classes that can be (de)serialized to/from JSON.
This is useful for accessing the resources that are published by this application, but only
......@@ -213,13 +213,13 @@
<tbody data-link="row" class="rowlink">
<tr class="clickable-row" data-href="drip-api-php.zip">
<td><span class="downloadfile-name">drip-api-php.zip</span></td>
<td><span class="downloadfile-size">6.58K</span></td>
<td><span class="downloadfile-size">6.77K</span></td>
<td><span class="downloadfile-description">&nbsp;</span></td>
</tr>
</tbody>
</table>
<h3 id="artifact_php_xml_client_library">PHP XML Client Library</h3>
<p class="lead">Created November 21, 2017</p>
<p class="lead">Created November 22, 2017</p>
<p><p>
The PHP client-side library defines the PHP classes that can be (de)serialized to/from XML.
This is useful for accessing the resources that are published by this application, but only
......@@ -251,7 +251,7 @@
</tbody>
</table>
<h3 id="artifact_ruby_json_client_library">Ruby JSON Client Library</h3>
<p class="lead">Created November 21, 2017</p>
<p class="lead">Created November 22, 2017</p>
<p><p>
The Ruby JSON client-side library defines the Ruby classes that can be (de)serialized to/from JSON.
This is useful for accessing the REST endpoints that are published by this application, but only
......
......@@ -93,208 +93,92 @@ module V1
module External
module Ansible
# (no documentation provided)
class AnsibleResult
class DeployParameter
# (no documentation provided)
attr_accessor :msg
# (no documentation provided)
attr_accessor :changed
# (no documentation provided)
attr_accessor :end
# (no documentation provided)
attr_accessor :stdout
# (no documentation provided)
attr_accessor :cmd
# (no documentation provided)
attr_accessor :start
# (no documentation provided)
attr_accessor :stderr
# (no documentation provided)
attr_accessor :delta
# the IP
attr_accessor :IP
# the user
attr_accessor :user
# the role
attr_accessor :role
# the json hash for this AnsibleResult
# the json hash for this DeployParameter
def to_jaxb_json_hash
_h = {}
_h['msg'] = msg.to_jaxb_json_hash unless msg.nil?
_h['changed'] = changed.to_jaxb_json_hash unless changed.nil?
_h['end'] = end.to_jaxb_json_hash unless end.nil?
_h['stdout'] = stdout.to_jaxb_json_hash unless stdout.nil?
if !cmd.nil?
_ha = Array.new
cmd.each { | _item | _ha.push _item.to_jaxb_json_hash }
_h['cmd'] = _ha
end
_h['start'] = start.to_jaxb_json_hash unless start.nil?
_h['stderr'] = stderr.to_jaxb_json_hash unless stderr.nil?
_h['delta'] = delta.to_jaxb_json_hash unless delta.nil?
_h['IP'] = IP.to_jaxb_json_hash unless IP.nil?
_h['user'] = user.to_jaxb_json_hash unless user.nil?
_h['role'] = role.to_jaxb_json_hash unless role.nil?
return _h
end
# the json (string form) for this AnsibleResult
# the json (string form) for this DeployParameter
def to_json
to_jaxb_json_hash.to_json
end
#initializes this AnsibleResult with a json hash
#initializes this DeployParameter with a json hash
def init_jaxb_json_hash(_o)
if !_o['msg'].nil?
_oa = _o['msg']
if(_oa.is_a? Hash)
@msg = EnunciateHelpers::LAMB_CLASS_AWARE.call(_oa) if _oa['@class']
@msg = String.from_json(_oa) unless _oa['@class']
elsif (_oa.is_a? Array)
#an array(of hashes hopefully) or scalar
@msg = Array.new
_oa.each { | _item |
if ((_item.nil? || _item['@class'].nil?)rescue true)
@msg.push String.from_json(_item)
else
@msg.push EnunciateHelpers::LAMB_CLASS_AWARE.call(_item)
end
}
else
@msg = _oa
end
end
if !_o['changed'].nil?
_oa = _o['changed']
if(_oa.is_a? Hash)
@changed = EnunciateHelpers::LAMB_CLASS_AWARE.call(_oa) if _oa['@class']
@changed = Boolean.from_json(_oa) unless _oa['@class']
elsif (_oa.is_a? Array)
#an array(of hashes hopefully) or scalar
@changed = Array.new
_oa.each { | _item |
if ((_item.nil? || _item['@class'].nil?)rescue true)
@changed.push Boolean.from_json(_item)
else
@changed.push EnunciateHelpers::LAMB_CLASS_AWARE.call(_item)
end
}
else
@changed = _oa
end
end
if !_o['end'].nil?
_oa = _o['end']
if(_oa.is_a? Hash)
@end = EnunciateHelpers::LAMB_CLASS_AWARE.call(_oa) if _oa['@class']
@end = Time.from_json(_oa) unless _oa['@class']
elsif (_oa.is_a? Array)
#an array(of hashes hopefully) or scalar
@end = Array.new
_oa.each { | _item |
if ((_item.nil? || _item['@class'].nil?)rescue true)
@end.push Time.from_json(_item)
else
@end.push EnunciateHelpers::LAMB_CLASS_AWARE.call(_item)
end
}
else
@end = _oa
end
end
if !_o['stdout'].nil?
_oa = _o['stdout']
if(_oa.is_a? Hash)
@stdout = EnunciateHelpers::LAMB_CLASS_AWARE.call(_oa) if _oa['@class']
@stdout = String.from_json(_oa) unless _oa['@class']
elsif (_oa.is_a? Array)
#an array(of hashes hopefully) or scalar
@stdout = Array.new
_oa.each { | _item |
if ((_item.nil? || _item['@class'].nil?)rescue true)
@stdout.push String.from_json(_item)
else
@stdout.push EnunciateHelpers::LAMB_CLASS_AWARE.call(_item)
end
}
else
@stdout = _oa
end
end
if !_o['cmd'].nil?
_oa = _o['cmd']
if(_oa.is_a? Hash)
@cmd = EnunciateHelpers::LAMB_CLASS_AWARE.call(_oa) if _oa['@class']
@cmd = String.from_json(_oa) unless _oa['@class']
elsif (_oa.is_a? Array)
#an array(of hashes hopefully) or scalar
@cmd = Array.new
_oa.each { | _item |
if ((_item.nil? || _item['@class'].nil?)rescue true)
@cmd.push String.from_json(_item)
else
@cmd.push EnunciateHelpers::LAMB_CLASS_AWARE.call(_item)
end
}
else
@cmd = _oa
end
end
if !_o['start'].nil?
_oa = _o['start']
if !_o['IP'].nil?
_oa = _o['IP']
if(_oa.is_a? Hash)
@start = EnunciateHelpers::LAMB_CLASS_AWARE.call(_oa) if _oa['@class']
@start = Time.from_json(_oa) unless _oa['@class']
@IP = EnunciateHelpers::LAMB_CLASS_AWARE.call(_oa) if _oa['@class']
@IP = String.from_json(_oa) unless _oa['@class']
elsif (_oa.is_a? Array)
#an array(of hashes hopefully) or scalar
@start = Array.new
@IP = Array.new
_oa.each { | _item |
if ((_item.nil? || _item['@class'].nil?)rescue true)
@start.push Time.from_json(_item)
@IP.push String.from_json(_item)
else
@start.push EnunciateHelpers::LAMB_CLASS_AWARE.call(_item)
@IP.push EnunciateHelpers::LAMB_CLASS_AWARE.call(_item)
end
}
else
@start = _oa
@IP = _oa
end
end
if !_o['stderr'].nil?
_oa = _o['stderr']
if !_o['user'].nil?
_oa = _o['user']
if(_oa.is_a? Hash)
@stderr = EnunciateHelpers::LAMB_CLASS_AWARE.call(_oa) if _oa['@class']
@stderr = String.from_json(_oa) unless _oa['@class']
@user = EnunciateHelpers::LAMB_CLASS_AWARE.call(_oa) if _oa['@class']
@user = String.from_json(_oa) unless _oa['@class']
elsif (_oa.is_a? Array)
#an array(of hashes hopefully) or scalar
@stderr = Array.new
@user = Array.new
_oa.each { | _item |
if ((_item.nil? || _item['@class'].nil?)rescue true)
@stderr.push String.from_json(_item)
@user.push String.from_json(_item)
else
@stderr.push EnunciateHelpers::LAMB_CLASS_AWARE.call(_item)
@user.push EnunciateHelpers::LAMB_CLASS_AWARE.call(_item)
end
}
else
@stderr = _oa
@user = _oa
end
end
if !_o['delta'].nil?
_oa = _o['delta']
if !_o['role'].nil?
_oa = _o['role']
if(_oa.is_a? Hash)
@delta = EnunciateHelpers::LAMB_CLASS_AWARE.call(_oa) if _oa['@class']
@delta = Time.from_json(_oa) unless _oa['@class']
@role = EnunciateHelpers::LAMB_CLASS_AWARE.call(_oa) if _oa['@class']
@role = String.from_json(_oa) unless _oa['@class']
elsif (_oa.is_a? Array)
#an array(of hashes hopefully) or scalar
@delta = Array.new
@role = Array.new
_oa.each { | _item |
if ((_item.nil? || _item['@class'].nil?)rescue true)
@delta.push Time.from_json(_item)
@role.push String.from_json(_item)
else
@delta.push EnunciateHelpers::LAMB_CLASS_AWARE.call(_item)
@role.push EnunciateHelpers::LAMB_CLASS_AWARE.call(_item)
end
}
else
@delta = _oa
@role = _oa
end
end
end
# constructs a AnsibleResult from a (parsed) JSON hash
# constructs a DeployParameter from a (parsed) JSON hash
def self.from_json(o)
if o.nil?
return nil
......@@ -324,8 +208,6 @@ end
end
end
module Nl
module Uva
......@@ -477,92 +359,208 @@ module V1
module External
module Ansible
# (no documentation provided)
class DeployParameter
class AnsibleResult
# the IP
attr_accessor :IP
# the user
attr_accessor :user
# the role
attr_accessor :role
# (no documentation provided)
attr_accessor :msg
# (no documentation provided)
attr_accessor :changed
# (no documentation provided)
attr_accessor :end
# (no documentation provided)
attr_accessor :stdout
# (no documentation provided)
attr_accessor :cmd
# (no documentation provided)
attr_accessor :start
# (no documentation provided)
attr_accessor :stderr
# (no documentation provided)
attr_accessor :delta
# the json hash for this DeployParameter
# the json hash for this AnsibleResult
def to_jaxb_json_hash
_h = {}
_h['IP'] = IP.to_jaxb_json_hash unless IP.nil?
_h['user'] = user.to_jaxb_json_hash unless user.nil?
_h['role'] = role.to_jaxb_json_hash unless role.nil?
_h['msg'] = msg.to_jaxb_json_hash unless msg.nil?
_h['changed'] = changed.to_jaxb_json_hash unless changed.nil?
_h['end'] = end.to_jaxb_json_hash unless end.nil?
_h['stdout'] = stdout.to_jaxb_json_hash unless stdout.nil?
if !cmd.nil?
_ha = Array.new
cmd.each { | _item | _ha.push _item.to_jaxb_json_hash }
_h['cmd'] = _ha
end
_h['start'] = start.to_jaxb_json_hash unless start.nil?
_h['stderr'] = stderr.to_jaxb_json_hash unless stderr.nil?
_h['delta'] = delta.to_jaxb_json_hash unless delta.nil?
return _h
end
# the json (string form) for this DeployParameter
# the json (string form) for this AnsibleResult
def to_json
to_jaxb_json_hash.to_json
end
#initializes this DeployParameter with a json hash
#initializes this AnsibleResult with a json hash
def init_jaxb_json_hash(_o)
if !_o['IP'].nil?
_oa = _o['IP']
if !_o['msg'].nil?
_oa = _o['msg']
if(_oa.is_a? Hash)
@IP = EnunciateHelpers::LAMB_CLASS_AWARE.call(_oa) if _oa['@class']
@IP = String.from_json(_oa) unless _oa['@class']
@msg = EnunciateHelpers::LAMB_CLASS_AWARE.call(_oa) if _oa['@class']
@msg = String.from_json(_oa) unless _oa['@class']
elsif (_oa.is_a? Array)
#an array(of hashes hopefully) or scalar
@IP = Array.new
@msg = Array.new
_oa.each { | _item |
if ((_item.nil? || _item['@class'].nil?)rescue true)
@IP.push String.from_json(_item)
@msg.push String.from_json(_item)
else
@IP.push EnunciateHelpers::LAMB_CLASS_AWARE.call(_item)
@msg.push EnunciateHelpers::LAMB_CLASS_AWARE.call(_item)
end
}
else
@IP = _oa
@msg = _oa
end
end
if !_o['user'].nil?
_oa = _o['user']
if !_o['changed'].nil?
_oa = _o['changed']
if(_oa.is_a? Hash)
@user = EnunciateHelpers::LAMB_CLASS_AWARE.call(_oa) if _oa['@class']
@user = String.from_json(_oa) unless _oa['@class']
@changed = EnunciateHelpers::LAMB_CLASS_AWARE.call(_oa) if _oa['@class']
@changed = Boolean.from_json(_oa) unless _oa['@class']
elsif (_oa.is_a? Array)
#an array(of hashes hopefully) or scalar
@user = Array.new
@changed = Array.new
_oa.each { | _item |
if ((_item.nil? || _item['@class'].nil?)rescue true)
@user.push String.from_json(_item)
@changed.push Boolean.from_json(_item)
else
@user.push EnunciateHelpers::LAMB_CLASS_AWARE.call(_item)
@changed.push EnunciateHelpers::LAMB_CLASS_AWARE.call(_item)
end
}
else
@user = _oa
@changed = _oa
end
end
if !_o['role'].nil?
_oa = _o['role']
if !_o['end'].nil?
_oa = _o['end']
if(_oa.is_a? Hash)
@role = EnunciateHelpers::LAMB_CLASS_AWARE.call(_oa) if _oa['@class']
@role = String.from_json(_oa) unless _oa['@class']
@end = EnunciateHelpers::LAMB_CLASS_AWARE.call(_oa) if _oa['@class']
@end = Time.from_json(_oa) unless _oa['@class']
elsif (_oa.is_a? Array)
#an array(of hashes hopefully) or scalar
@role = Array.new
@end = Array.new
_oa.each { | _item |
if ((_item.nil? || _item['@class'].nil?)rescue true)
@role.push String.from_json(_item)
@end.push Time.from_json(_item)
else
@role.push EnunciateHelpers::LAMB_CLASS_AWARE.call(_item)
@end.push EnunciateHelpers::LAMB_CLASS_AWARE.call(_item)
end
}
else
@role = _oa
@end = _oa
end
end
if !_o['stdout'].nil?
_oa = _o['stdout']
if(_oa.is_a? Hash)
@stdout = EnunciateHelpers::LAMB_CLASS_AWARE.call(_oa) if _oa['@class']
@stdout = String.from_json(_oa) unless _oa['@class']
elsif (_oa.is_a? Array)
#an array(of hashes hopefully) or scalar
@stdout = Array.new
_oa.each { | _item |
if ((_item.nil? || _item['@class'].nil?)rescue true)
@stdout.push String.from_json(_item)
else
@stdout.push EnunciateHelpers::LAMB_CLASS_AWARE.call(_item)
end
}
else
@stdout = _oa
end
end
if !_o['cmd'].nil?
_oa = _o['cmd']
if(_oa.is_a? Hash)
@cmd = EnunciateHelpers::LAMB_CLASS_AWARE.call(_oa) if _oa['@class']
@cmd = String.from_json(_oa) unless _oa['@class']
elsif (_oa.is_a? Array)
#an array(of hashes hopefully) or scalar
@cmd = Array.new
_oa.each { | _item |
if ((_item.nil? || _item['@class'].nil?)rescue true)
@cmd.push String.from_json(_item)
else
@cmd.push EnunciateHelpers::LAMB_CLASS_AWARE.call(_item)
end
}
else
@cmd = _oa
end
end
if !_o['start'].nil?
_oa = _o['start']
if(_oa.is_a? Hash)
@start = EnunciateHelpers::LAMB_CLASS_AWARE.call(_oa) if _oa['@class']
@start = Time.from_json(_oa) unless _oa['@class']
elsif (_oa.is_a? Array)
#an array(of hashes hopefully) or scalar
@start = Array.new
_oa.each { | _item |
if ((_item.nil? || _item['@class'].nil?)rescue true)
@start.push Time.from_json(_item)
else
@start.push EnunciateHelpers::LAMB_CLASS_AWARE.call(_item)
end
}
else
@start = _oa
end
end
if !_o['stderr'].nil?
_oa = _o['stderr']
if(_oa.is_a? Hash)
@stderr = EnunciateHelpers::LAMB_CLASS_AWARE.call(_oa) if _oa['@class']
@stderr = String.from_json(_oa) unless _oa['@class']
elsif (_oa.is_a? Array)
#an array(of hashes hopefully) or scalar
@stderr = Array.new
_oa.each { | _item |
if ((_item.nil? || _item['@class'].nil?)rescue true)
@stderr.push String.from_json(_item)
else
@stderr.push EnunciateHelpers::LAMB_CLASS_AWARE.call(_item)
end
}
else
@stderr = _oa
end
end
if !_o['delta'].nil?
_oa = _o['delta']
if(_oa.is_a? Hash)
@delta = EnunciateHelpers::LAMB_CLASS_AWARE.call(_oa) if _oa['@class']
@delta = Time.from_json(_oa) unless _oa['@class']
elsif (_oa.is_a? Array)
#an array(of hashes hopefully) or scalar
@delta = Array.new
_oa.each { | _item |
if ((_item.nil? || _item['@class'].nil?)rescue true)
@delta.push Time.from_json(_item)
else
@delta.push EnunciateHelpers::LAMB_CLASS_AWARE.call(_item)
end
}
else
@delta = _oa
end
end
end
# constructs a DeployParameter from a (parsed) JSON hash
# constructs a AnsibleResult from a (parsed) JSON hash
def self.from_json(o)
if o.nil?
return nil
......@@ -592,6 +590,8 @@ end
end
end
module Nl
module Uva
......@@ -1012,285 +1012,309 @@ module V1
module External
module Ansible
# (no documentation provided)
class ScaleRequest < Nl::Uva::Sne::Drip::Drip::Commons::Data::V1::External::OwnedObject
class AnsibleOutput < Nl::Uva::Sne::Drip::Drip::Commons::Data::V1::External::OwnedObject
# the scaleTargetID
attr_accessor :scaleTargetID
# the scaleTargetName
attr_accessor :scaleTargetName
# the numOfInstances
attr_accessor :numOfInstances
# the host
attr_accessor :host
# the result
attr_accessor :result
# the domain
attr_accessor :cloudDeploymentDomain
#
attr_accessor :vmType
# the provision ID
attr_accessor :provisionID
# the cloudProvider
attr_accessor :cloudProvider
# the json hash for this ScaleRequest
# the json hash for this AnsibleOutput
def to_jaxb_json_hash
_h = super
_h['scaleTargetID'] = scaleTargetID.to_jaxb_json_hash unless scaleTargetID.nil?
_h['scaleTargetName'] = scaleTargetName.to_jaxb_json_hash unless scaleTargetName.nil?
_h['numOfInstances'] = numOfInstances.to_jaxb_json_hash unless numOfInstances.nil?
_h['host'] = host.to_jaxb_json_hash unless host.nil?
_h['result'] = result.to_jaxb_json_hash unless result.nil?
_h['cloudDeploymentDomain'] = cloudDeploymentDomain.to_jaxb_json_hash unless cloudDeploymentDomain.nil?
_h['vmType'] = vmType.to_jaxb_json_hash unless vmType.nil?
_h['provisionID'] = provisionID.to_jaxb_json_hash unless provisionID.nil?
_h['cloudProvider'] = cloudProvider.to_jaxb_json_hash unless cloudProvider.nil?
return _h
end
#initializes this ScaleRequest with a json hash
#initializes this AnsibleOutput with a json hash
def init_jaxb_json_hash(_o)
super _o
if !_o['scaleTargetID'].nil?
_oa = _o['scaleTargetID']
if !_o['host'].nil?
_oa = _o['host']
if(_oa.is_a? Hash)
@scaleTargetID = EnunciateHelpers::LAMB_CLASS_AWARE.call(_oa) if _oa['@class']
@scaleTargetID = String.from_json(_oa) unless _oa['@class']
@host = EnunciateHelpers::LAMB_CLASS_AWARE.call(_oa) if _oa['@class']
@host = String.from_json(_oa) unless _oa['@class']
elsif (_oa.is_a? Array)
#an array(of hashes hopefully) or scalar
@scaleTargetID = Array.new
@host = Array.new
_oa.each { | _item |
if ((_item.nil? || _item['@class'].nil?)rescue true)
@scaleTargetID.push String.from_json(_item)
@host.push String.from_json(_item)
else
@scaleTargetID.push EnunciateHelpers::LAMB_CLASS_AWARE.call(_item)
@host.push EnunciateHelpers::LAMB_CLASS_AWARE.call(_item)
end
}
else
@scaleTargetID = _oa
@host = _oa
end
end
if !_o['scaleTargetName'].nil?
_oa = _o['scaleTargetName']
if !_o['result'].nil?
_oa = _o['result']
if(_oa.is_a? Hash)
@scaleTargetName = EnunciateHelpers::LAMB_CLASS_AWARE.call(_oa) if _oa['@class']
@scaleTargetName = String.from_json(_oa) unless _oa['@class']
@result = EnunciateHelpers::LAMB_CLASS_AWARE.call(_oa) if _oa['@class']
@result = Nl::Uva::Sne::Drip::Drip::Commons::Data::V1::External::Ansible::AnsibleResult.from_json(_oa) unless _oa['@class']
elsif (_oa.is_a? Array)
#an array(of hashes hopefully) or scalar
@scaleTargetName = Array.new
@result = Array.new
_oa.each { | _item |
if ((_item.nil? || _item['@class'].nil?)rescue true)
@scaleTargetName.push String.from_json(_item)
@result.push Nl::Uva::Sne::Drip::Drip::Commons::Data::V1::External::Ansible::AnsibleResult.from_json(_item)
else
@scaleTargetName.push EnunciateHelpers::LAMB_CLASS_AWARE.call(_item)
@result.push EnunciateHelpers::LAMB_CLASS_AWARE.call(_item)
end
}
else
@scaleTargetName = _oa
@result = _oa
end
end
if !_o['numOfInstances'].nil?
_oa = _o['numOfInstances']
if !_o['cloudDeploymentDomain'].nil?
_oa = _o['cloudDeploymentDomain']
if(_oa.is_a? Hash)
@numOfInstances = EnunciateHelpers::LAMB_CLASS_AWARE.call(_oa) if _oa['@class']
@numOfInstances = Fixnum.from_json(_oa) unless _oa['@class']
@cloudDeploymentDomain = EnunciateHelpers::LAMB_CLASS_AWARE.call(_oa) if _oa['@class']
@cloudDeploymentDomain = String.from_json(_oa) unless _oa['@class']
elsif (_oa.is_a? Array)
#an array(of hashes hopefully) or scalar
@numOfInstances = Array.new
@cloudDeploymentDomain = Array.new
_oa.each { | _item |
if ((_item.nil? || _item['@class'].nil?)rescue true)
@numOfInstances.push Fixnum.from_json(_item)
@cloudDeploymentDomain.push String.from_json(_item)
else
@numOfInstances.push EnunciateHelpers::LAMB_CLASS_AWARE.call(_item)
@cloudDeploymentDomain.push EnunciateHelpers::LAMB_CLASS_AWARE.call(_item)
end
}
else
@numOfInstances = _oa
@cloudDeploymentDomain = _oa
end
end
end
# constructs a ScaleRequest from a (parsed) JSON hash
def self.from_json(o)
if o.nil?
return nil
else
inst = new
inst.init_jaxb_json_hash o
return inst
end
end
end
end
end
end
end
end
end
end
end
end
module Nl
module Uva
module Sne
module Drip
module Drip
module Commons
module Data
module V1
module External
module Ansible
# (no documentation provided)
class BenchmarkResult < Nl::Uva::Sne::Drip::Drip::Commons::Data::V1::External::OwnedObject
# (no documentation provided)
attr_accessor :delta
# (no documentation provided)
attr_accessor :cloudDeploymentDomain
# (no documentation provided)
attr_accessor :vmType
# (no documentation provided)
attr_accessor :host
# (no documentation provided)
attr_accessor :start
# (no documentation provided)
attr_accessor :end
# the json hash for this BenchmarkResult
def to_jaxb_json_hash
_h = super
_h['delta'] = delta.to_jaxb_json_hash unless delta.nil?
_h['cloudDeploymentDomain'] = cloudDeploymentDomain.to_jaxb_json_hash unless cloudDeploymentDomain.nil?
_h['vmType'] = vmType.to_jaxb_json_hash unless vmType.nil?
_h['host'] = host.to_jaxb_json_hash unless host.nil?
_h['start'] = start.to_jaxb_json_hash unless start.nil?
_h['end'] = end.to_jaxb_json_hash unless end.nil?
return _h
end
#initializes this BenchmarkResult with a json hash
def init_jaxb_json_hash(_o)
super _o
if !_o['delta'].nil?
_oa = _o['delta']
if !_o['vmType'].nil?
_oa = _o['vmType']
if(_oa.is_a? Hash)
@delta = EnunciateHelpers::LAMB_CLASS_AWARE.call(_oa) if _oa['@class']
@delta = Time.from_json(_oa) unless _oa['@class']
@vmType = EnunciateHelpers::LAMB_CLASS_AWARE.call(_oa) if _oa['@class']
@vmType = String.from_json(_oa) unless _oa['@class']
elsif (_oa.is_a? Array)
#an array(of hashes hopefully) or scalar
@delta = Array.new
@vmType = Array.new
_oa.each { | _item |
if ((_item.nil? || _item['@class'].nil?)rescue true)
@delta.push Time.from_json(_item)
@vmType.push String.from_json(_item)
else
@delta.push EnunciateHelpers::LAMB_CLASS_AWARE.call(_item)
@vmType.push EnunciateHelpers::LAMB_CLASS_AWARE.call(_item)
end
}
else
@delta = _oa
@vmType = _oa
end
end
if !_o['cloudDeploymentDomain'].nil?
_oa = _o['cloudDeploymentDomain']
if !_o['provisionID'].nil?
_oa = _o['provisionID']
if(_oa.is_a? Hash)
@cloudDeploymentDomain = EnunciateHelpers::LAMB_CLASS_AWARE.call(_oa) if _oa['@class']
@cloudDeploymentDomain = String.from_json(_oa) unless _oa['@class']
@provisionID = EnunciateHelpers::LAMB_CLASS_AWARE.call(_oa) if _oa['@class']
@provisionID = String.from_json(_oa) unless _oa['@class']
elsif (_oa.is_a? Array)
#an array(of hashes hopefully) or scalar
@cloudDeploymentDomain = Array.new
@provisionID = Array.new
_oa.each { | _item |
if ((_item.nil? || _item['@class'].nil?)rescue true)
@cloudDeploymentDomain.push String.from_json(_item)
@provisionID.push String.from_json(_item)
else
@cloudDeploymentDomain.push EnunciateHelpers::LAMB_CLASS_AWARE.call(_item)
@provisionID.push EnunciateHelpers::LAMB_CLASS_AWARE.call(_item)
end
}
else
@cloudDeploymentDomain = _oa
@provisionID = _oa
end
end
if !_o['vmType'].nil?
_oa = _o['vmType']
if !_o['cloudProvider'].nil?
_oa = _o['cloudProvider']
if(_oa.is_a? Hash)
@vmType = EnunciateHelpers::LAMB_CLASS_AWARE.call(_oa) if _oa['@class']
@vmType = String.from_json(_oa) unless _oa['@class']
@cloudProvider = EnunciateHelpers::LAMB_CLASS_AWARE.call(_oa) if _oa['@class']
@cloudProvider = String.from_json(_oa) unless _oa['@class']
elsif (_oa.is_a? Array)
#an array(of hashes hopefully) or scalar
@vmType = Array.new
@cloudProvider = Array.new
_oa.each { | _item |
if ((_item.nil? || _item['@class'].nil?)rescue true)
@vmType.push String.from_json(_item)
@cloudProvider.push String.from_json(_item)
else
@vmType.push EnunciateHelpers::LAMB_CLASS_AWARE.call(_item)
@cloudProvider.push EnunciateHelpers::LAMB_CLASS_AWARE.call(_item)
end
}
else
@vmType = _oa
@cloudProvider = _oa
end
end
if !_o['host'].nil?
_oa = _o['host']
end
# constructs a AnsibleOutput from a (parsed) JSON hash
def self.from_json(o)
if o.nil?
return nil
else
inst = new
inst.init_jaxb_json_hash o
return inst
end
end
end
end
end
end
end
end
end
end
end
end
end
module Nl
module Uva
module Sne
module Drip
module Drip
module Commons
module Data
module V1
module External
# (no documentation provided)
class CloudCredentials < Nl::Uva::Sne::Drip::Drip::Commons::Data::V1::External::OwnedObject
# the secret key
attr_accessor :secretKey
# the cloudProviderName
attr_accessor :cloudProviderName
# the accessKeyId
attr_accessor :accessKeyId
# the attributes
attr_accessor :attributes
# the json hash for this CloudCredentials
def to_jaxb_json_hash
_h = super
_h['secretKey'] = secretKey.to_jaxb_json_hash unless secretKey.nil?
_h['cloudProviderName'] = cloudProviderName.to_jaxb_json_hash unless cloudProviderName.nil?
_h['accessKeyId'] = accessKeyId.to_jaxb_json_hash unless accessKeyId.nil?
_h['attributes'] = attributes.to_jaxb_json_hash unless attributes.nil?
return _h
end
#initializes this CloudCredentials with a json hash
def init_jaxb_json_hash(_o)
super _o
if !_o['secretKey'].nil?
_oa = _o['secretKey']
if(_oa.is_a? Hash)
@host = EnunciateHelpers::LAMB_CLASS_AWARE.call(_oa) if _oa['@class']
@host = String.from_json(_oa) unless _oa['@class']
@secretKey = EnunciateHelpers::LAMB_CLASS_AWARE.call(_oa) if _oa['@class']
@secretKey = String.from_json(_oa) unless _oa['@class']
elsif (_oa.is_a? Array)
#an array(of hashes hopefully) or scalar
@host = Array.new
@secretKey = Array.new
_oa.each { | _item |
if ((_item.nil? || _item['@class'].nil?)rescue true)
@host.push String.from_json(_item)
@secretKey.push String.from_json(_item)
else
@host.push EnunciateHelpers::LAMB_CLASS_AWARE.call(_item)
@secretKey.push EnunciateHelpers::LAMB_CLASS_AWARE.call(_item)
end
}
else
@host = _oa
@secretKey = _oa
end
end
if !_o['start'].nil?
_oa = _o['start']
if !_o['cloudProviderName'].nil?
_oa = _o['cloudProviderName']
if(_oa.is_a? Hash)
@start = EnunciateHelpers::LAMB_CLASS_AWARE.call(_oa) if _oa['@class']
@start = Time.from_json(_oa) unless _oa['@class']
@cloudProviderName = EnunciateHelpers::LAMB_CLASS_AWARE.call(_oa) if _oa['@class']
@cloudProviderName = String.from_json(_oa) unless _oa['@class']
elsif (_oa.is_a? Array)
#an array(of hashes hopefully) or scalar
@start = Array.new
@cloudProviderName = Array.new
_oa.each { | _item |
if ((_item.nil? || _item['@class'].nil?)rescue true)
@start.push Time.from_json(_item)
@cloudProviderName.push String.from_json(_item)
else
@start.push EnunciateHelpers::LAMB_CLASS_AWARE.call(_item)
@cloudProviderName.push EnunciateHelpers::LAMB_CLASS_AWARE.call(_item)
end
}
else
@start = _oa
@cloudProviderName = _oa
end
end
if !_o['end'].nil?
_oa = _o['end']
if !_o['accessKeyId'].nil?
_oa = _o['accessKeyId']
if(_oa.is_a? Hash)
@end = EnunciateHelpers::LAMB_CLASS_AWARE.call(_oa) if _oa['@class']
@end = Time.from_json(_oa) unless _oa['@class']
@accessKeyId = EnunciateHelpers::LAMB_CLASS_AWARE.call(_oa) if _oa['@class']
@accessKeyId = String.from_json(_oa) unless _oa['@class']
elsif (_oa.is_a? Array)
#an array(of hashes hopefully) or scalar
@end = Array.new
@accessKeyId = Array.new
_oa.each { | _item |
if ((_item.nil? || _item['@class'].nil?)rescue true)
@end.push Time.from_json(_item)
@accessKeyId.push String.from_json(_item)
else
@end.push EnunciateHelpers::LAMB_CLASS_AWARE.call(_item)
@accessKeyId.push EnunciateHelpers::LAMB_CLASS_AWARE.call(_item)
end
}
else
@end = _oa
@accessKeyId = _oa
end
end
if !_o['attributes'].nil?
_oa = _o['attributes']
if(_oa.is_a? Hash)
@attributes = EnunciateHelpers::LAMB_CLASS_AWARE.call(_oa) if _oa['@class']
@attributes = Hash.from_json(_oa) unless _oa['@class']
elsif (_oa.is_a? Array)
#an array(of hashes hopefully) or scalar
@attributes = Array.new
_oa.each { | _item |
if ((_item.nil? || _item['@class'].nil?)rescue true)
@attributes.push Hash.from_json(_item)
else
@attributes.push EnunciateHelpers::LAMB_CLASS_AWARE.call(_item)
end
}
else
@attributes = _oa
end
end
end
# constructs a BenchmarkResult from a (parsed) JSON hash
# constructs a CloudCredentials from a (parsed) JSON hash
def self.from_json(o)
if o.nil?
return nil
......@@ -1320,8 +1344,6 @@ end
end
end
module Nl
module Uva
......@@ -1711,24 +1733,153 @@ module V1
module External
# (no documentation provided)
class MonitorringMessage < Nl::Uva::Sne::Drip::Drip::Commons::Data::V1::External::OwnedObject
# the metricMame
attr_accessor :metricMame
# the subid
attr_accessor :subid
# the value
attr_accessor :value
# the messageType
attr_accessor :messageType
# the date
attr_accessor :date
# the time
attr_accessor :time
class DeployRequest < Nl::Uva::Sne::Drip::Drip::Commons::Data::V1::External::OwnedObject
# the json hash for this MonitorringMessage
def to_jaxb_json_hash
_h = super
# the provisionID
attr_accessor :provisionID
# the managerType
attr_accessor :managerType
# the configurationID
attr_accessor :configurationID
# the json hash for this DeployRequest
def to_jaxb_json_hash
_h = super
_h['provisionID'] = provisionID.to_jaxb_json_hash unless provisionID.nil?
_h['managerType'] = managerType.to_jaxb_json_hash unless managerType.nil?
_h['configurationID'] = configurationID.to_jaxb_json_hash unless configurationID.nil?
return _h
end
#initializes this DeployRequest with a json hash
def init_jaxb_json_hash(_o)
super _o
if !_o['provisionID'].nil?
_oa = _o['provisionID']
if(_oa.is_a? Hash)
@provisionID = EnunciateHelpers::LAMB_CLASS_AWARE.call(_oa) if _oa['@class']
@provisionID = String.from_json(_oa) unless _oa['@class']
elsif (_oa.is_a? Array)
#an array(of hashes hopefully) or scalar
@provisionID = Array.new
_oa.each { | _item |
if ((_item.nil? || _item['@class'].nil?)rescue true)
@provisionID.push String.from_json(_item)
else
@provisionID.push EnunciateHelpers::LAMB_CLASS_AWARE.call(_item)
end
}
else
@provisionID = _oa
end
end
if !_o['managerType'].nil?
_oa = _o['managerType']
if(_oa.is_a? Hash)
@managerType = EnunciateHelpers::LAMB_CLASS_AWARE.call(_oa) if _oa['@class']
@managerType = String.from_json(_oa) unless _oa['@class']
elsif (_oa.is_a? Array)
#an array(of hashes hopefully) or scalar
@managerType = Array.new
_oa.each { | _item |
if ((_item.nil? || _item['@class'].nil?)rescue true)
@managerType.push String.from_json(_item)
else
@managerType.push EnunciateHelpers::LAMB_CLASS_AWARE.call(_item)
end
}
else
@managerType = _oa
end
end
if !_o['configurationID'].nil?
_oa = _o['configurationID']
if(_oa.is_a? Hash)
@configurationID = EnunciateHelpers::LAMB_CLASS_AWARE.call(_oa) if _oa['@class']
@configurationID = String.from_json(_oa) unless _oa['@class']
elsif (_oa.is_a? Array)
#an array(of hashes hopefully) or scalar
@configurationID = Array.new
_oa.each { | _item |
if ((_item.nil? || _item['@class'].nil?)rescue true)
@configurationID.push String.from_json(_item)
else
@configurationID.push EnunciateHelpers::LAMB_CLASS_AWARE.call(_item)
end
}
else
@configurationID = _oa
end
end
end
# constructs a DeployRequest from a (parsed) JSON hash
def self.from_json(o)
if o.nil?
return nil
else
inst = new
inst.init_jaxb_json_hash o
return inst
end
end
end
end
end
end
end
end
end
end
end
end
module Nl
module Uva
module Sne
module Drip
module Drip
module Commons
module Data
module V1
module External
# (no documentation provided)
class MonitorringMessage < Nl::Uva::Sne::Drip::Drip::Commons::Data::V1::External::OwnedObject
# the metricMame
attr_accessor :metricMame
# the subid
attr_accessor :subid
# the value
attr_accessor :value
# the messageType
attr_accessor :messageType
# the date
attr_accessor :date
# the time
attr_accessor :time
# the json hash for this MonitorringMessage
def to_jaxb_json_hash
_h = super
_h['metricMame'] = metricMame.to_jaxb_json_hash unless metricMame.nil?
_h['subid'] = subid.to_jaxb_json_hash unless subid.nil?
_h['value'] = value.to_jaxb_json_hash unless value.nil?
......@@ -1906,87 +2057,43 @@ module V1
module External
# (no documentation provided)
class DeployRequest < Nl::Uva::Sne::Drip::Drip::Commons::Data::V1::External::OwnedObject
class KeyValueHolder < Nl::Uva::Sne::Drip::Drip::Commons::Data::V1::External::OwnedObject
# the provisionID
attr_accessor :provisionID
# the managerType
attr_accessor :managerType
# the configurationID
attr_accessor :configurationID
# the keyValue
attr_accessor :keyValue
# the json hash for this DeployRequest
# the json hash for this KeyValueHolder
def to_jaxb_json_hash
_h = super
_h['provisionID'] = provisionID.to_jaxb_json_hash unless provisionID.nil?
_h['managerType'] = managerType.to_jaxb_json_hash unless managerType.nil?
_h['configurationID'] = configurationID.to_jaxb_json_hash unless configurationID.nil?
_h['keyValue'] = keyValue.to_jaxb_json_hash unless keyValue.nil?
return _h
end
#initializes this DeployRequest with a json hash
#initializes this KeyValueHolder with a json hash
def init_jaxb_json_hash(_o)
super _o
if !_o['provisionID'].nil?
_oa = _o['provisionID']
if(_oa.is_a? Hash)
@provisionID = EnunciateHelpers::LAMB_CLASS_AWARE.call(_oa) if _oa['@class']
@provisionID = String.from_json(_oa) unless _oa['@class']
elsif (_oa.is_a? Array)
#an array(of hashes hopefully) or scalar
@provisionID = Array.new
_oa.each { | _item |
if ((_item.nil? || _item['@class'].nil?)rescue true)
@provisionID.push String.from_json(_item)
else
@provisionID.push EnunciateHelpers::LAMB_CLASS_AWARE.call(_item)
end
}
else
@provisionID = _oa
end
end
if !_o['managerType'].nil?
_oa = _o['managerType']
if(_oa.is_a? Hash)
@managerType = EnunciateHelpers::LAMB_CLASS_AWARE.call(_oa) if _oa['@class']
@managerType = String.from_json(_oa) unless _oa['@class']
elsif (_oa.is_a? Array)
#an array(of hashes hopefully) or scalar
@managerType = Array.new
_oa.each { | _item |
if ((_item.nil? || _item['@class'].nil?)rescue true)
@managerType.push String.from_json(_item)
else
@managerType.push EnunciateHelpers::LAMB_CLASS_AWARE.call(_item)
end
}
else
@managerType = _oa
end
end
if !_o['configurationID'].nil?
_oa = _o['configurationID']
if !_o['keyValue'].nil?
_oa = _o['keyValue']
if(_oa.is_a? Hash)
@configurationID = EnunciateHelpers::LAMB_CLASS_AWARE.call(_oa) if _oa['@class']
@configurationID = String.from_json(_oa) unless _oa['@class']
@keyValue = EnunciateHelpers::LAMB_CLASS_AWARE.call(_oa) if _oa['@class']
@keyValue = Hash.from_json(_oa) unless _oa['@class']
elsif (_oa.is_a? Array)
#an array(of hashes hopefully) or scalar
@configurationID = Array.new
@keyValue = Array.new
_oa.each { | _item |
if ((_item.nil? || _item['@class'].nil?)rescue true)
@configurationID.push String.from_json(_item)
@keyValue.push Hash.from_json(_item)
else
@configurationID.push EnunciateHelpers::LAMB_CLASS_AWARE.call(_item)
@keyValue.push EnunciateHelpers::LAMB_CLASS_AWARE.call(_item)
end
}
else
@configurationID = _oa
@keyValue = _oa
end
end
end
# constructs a DeployRequest from a (parsed) JSON hash
# constructs a KeyValueHolder from a (parsed) JSON hash
def self.from_json(o)
if o.nil?
return nil
......@@ -2034,195 +2141,156 @@ module V1
module External
module Ansible
# (no documentation provided)
class KeyValueHolder < Nl::Uva::Sne::Drip::Drip::Commons::Data::V1::External::OwnedObject
class BenchmarkResult < Nl::Uva::Sne::Drip::Drip::Commons::Data::V1::External::OwnedObject
# the keyValue
attr_accessor :keyValue
# (no documentation provided)
attr_accessor :host
# (no documentation provided)
attr_accessor :vmType
# (no documentation provided)
attr_accessor :end
# (no documentation provided)
attr_accessor :cloudDeploymentDomain
# (no documentation provided)
attr_accessor :delta
# (no documentation provided)
attr_accessor :start
# the json hash for this KeyValueHolder
# the json hash for this BenchmarkResult
def to_jaxb_json_hash
_h = super
_h['keyValue'] = keyValue.to_jaxb_json_hash unless keyValue.nil?
_h['host'] = host.to_jaxb_json_hash unless host.nil?
_h['vmType'] = vmType.to_jaxb_json_hash unless vmType.nil?
_h['end'] = end.to_jaxb_json_hash unless end.nil?
_h['cloudDeploymentDomain'] = cloudDeploymentDomain.to_jaxb_json_hash unless cloudDeploymentDomain.nil?
_h['delta'] = delta.to_jaxb_json_hash unless delta.nil?
_h['start'] = start.to_jaxb_json_hash unless start.nil?
return _h
end
#initializes this KeyValueHolder with a json hash
#initializes this BenchmarkResult with a json hash
def init_jaxb_json_hash(_o)
super _o
if !_o['keyValue'].nil?
_oa = _o['keyValue']
if !_o['host'].nil?
_oa = _o['host']
if(_oa.is_a? Hash)
@keyValue = EnunciateHelpers::LAMB_CLASS_AWARE.call(_oa) if _oa['@class']
@keyValue = Hash.from_json(_oa) unless _oa['@class']
@host = EnunciateHelpers::LAMB_CLASS_AWARE.call(_oa) if _oa['@class']
@host = String.from_json(_oa) unless _oa['@class']
elsif (_oa.is_a? Array)
#an array(of hashes hopefully) or scalar
@keyValue = Array.new
@host = Array.new
_oa.each { | _item |
if ((_item.nil? || _item['@class'].nil?)rescue true)
@keyValue.push Hash.from_json(_item)
@host.push String.from_json(_item)
else
@keyValue.push EnunciateHelpers::LAMB_CLASS_AWARE.call(_item)
@host.push EnunciateHelpers::LAMB_CLASS_AWARE.call(_item)
end
}
else
@keyValue = _oa
@host = _oa
end
end
end
# constructs a KeyValueHolder from a (parsed) JSON hash
def self.from_json(o)
if o.nil?
return nil
else
inst = new
inst.init_jaxb_json_hash o
return inst
end
end
end
end
end
end
end
end
end
end
end
end
module Nl
module Uva
module Sne
module Drip
module Drip
module Commons
module Data
module V1
module External
# (no documentation provided)
class CloudCredentials < Nl::Uva::Sne::Drip::Drip::Commons::Data::V1::External::OwnedObject
# the secret key
attr_accessor :secretKey
# the cloudProviderName
attr_accessor :cloudProviderName
# the accessKeyId
attr_accessor :accessKeyId
# the attributes
attr_accessor :attributes
# the json hash for this CloudCredentials
def to_jaxb_json_hash
_h = super
_h['secretKey'] = secretKey.to_jaxb_json_hash unless secretKey.nil?
_h['cloudProviderName'] = cloudProviderName.to_jaxb_json_hash unless cloudProviderName.nil?
_h['accessKeyId'] = accessKeyId.to_jaxb_json_hash unless accessKeyId.nil?
_h['attributes'] = attributes.to_jaxb_json_hash unless attributes.nil?
return _h
end
#initializes this CloudCredentials with a json hash
def init_jaxb_json_hash(_o)
super _o
if !_o['secretKey'].nil?
_oa = _o['secretKey']
if !_o['vmType'].nil?
_oa = _o['vmType']
if(_oa.is_a? Hash)
@secretKey = EnunciateHelpers::LAMB_CLASS_AWARE.call(_oa) if _oa['@class']
@secretKey = String.from_json(_oa) unless _oa['@class']
@vmType = EnunciateHelpers::LAMB_CLASS_AWARE.call(_oa) if _oa['@class']
@vmType = String.from_json(_oa) unless _oa['@class']
elsif (_oa.is_a? Array)
#an array(of hashes hopefully) or scalar
@secretKey = Array.new
@vmType = Array.new
_oa.each { | _item |
if ((_item.nil? || _item['@class'].nil?)rescue true)
@secretKey.push String.from_json(_item)
@vmType.push String.from_json(_item)
else
@secretKey.push EnunciateHelpers::LAMB_CLASS_AWARE.call(_item)
@vmType.push EnunciateHelpers::LAMB_CLASS_AWARE.call(_item)
end
}
else
@secretKey = _oa
@vmType = _oa
end
end
if !_o['cloudProviderName'].nil?
_oa = _o['cloudProviderName']
if !_o['end'].nil?
_oa = _o['end']
if(_oa.is_a? Hash)
@cloudProviderName = EnunciateHelpers::LAMB_CLASS_AWARE.call(_oa) if _oa['@class']
@cloudProviderName = String.from_json(_oa) unless _oa['@class']
@end = EnunciateHelpers::LAMB_CLASS_AWARE.call(_oa) if _oa['@class']
@end = Time.from_json(_oa) unless _oa['@class']
elsif (_oa.is_a? Array)
#an array(of hashes hopefully) or scalar
@cloudProviderName = Array.new
@end = Array.new
_oa.each { | _item |
if ((_item.nil? || _item['@class'].nil?)rescue true)
@cloudProviderName.push String.from_json(_item)
@end.push Time.from_json(_item)
else
@cloudProviderName.push EnunciateHelpers::LAMB_CLASS_AWARE.call(_item)
@end.push EnunciateHelpers::LAMB_CLASS_AWARE.call(_item)
end
}
else
@cloudProviderName = _oa
@end = _oa
end
end
if !_o['accessKeyId'].nil?
_oa = _o['accessKeyId']
if !_o['cloudDeploymentDomain'].nil?
_oa = _o['cloudDeploymentDomain']
if(_oa.is_a? Hash)
@accessKeyId = EnunciateHelpers::LAMB_CLASS_AWARE.call(_oa) if _oa['@class']
@accessKeyId = String.from_json(_oa) unless _oa['@class']
@cloudDeploymentDomain = EnunciateHelpers::LAMB_CLASS_AWARE.call(_oa) if _oa['@class']
@cloudDeploymentDomain = String.from_json(_oa) unless _oa['@class']
elsif (_oa.is_a? Array)
#an array(of hashes hopefully) or scalar
@accessKeyId = Array.new
@cloudDeploymentDomain = Array.new
_oa.each { | _item |
if ((_item.nil? || _item['@class'].nil?)rescue true)
@accessKeyId.push String.from_json(_item)
@cloudDeploymentDomain.push String.from_json(_item)
else
@accessKeyId.push EnunciateHelpers::LAMB_CLASS_AWARE.call(_item)
@cloudDeploymentDomain.push EnunciateHelpers::LAMB_CLASS_AWARE.call(_item)
end
}
else
@accessKeyId = _oa
@cloudDeploymentDomain = _oa
end
end
if !_o['attributes'].nil?
_oa = _o['attributes']
if !_o['delta'].nil?
_oa = _o['delta']
if(_oa.is_a? Hash)
@attributes = EnunciateHelpers::LAMB_CLASS_AWARE.call(_oa) if _oa['@class']
@attributes = Hash.from_json(_oa) unless _oa['@class']
@delta = EnunciateHelpers::LAMB_CLASS_AWARE.call(_oa) if _oa['@class']
@delta = Time.from_json(_oa) unless _oa['@class']
elsif (_oa.is_a? Array)
#an array(of hashes hopefully) or scalar
@attributes = Array.new
@delta = Array.new
_oa.each { | _item |
if ((_item.nil? || _item['@class'].nil?)rescue true)
@attributes.push Hash.from_json(_item)
@delta.push Time.from_json(_item)
else
@attributes.push EnunciateHelpers::LAMB_CLASS_AWARE.call(_item)
@delta.push EnunciateHelpers::LAMB_CLASS_AWARE.call(_item)
end
}
else
@attributes = _oa
@delta = _oa
end
end
if !_o['start'].nil?
_oa = _o['start']
if(_oa.is_a? Hash)
@start = EnunciateHelpers::LAMB_CLASS_AWARE.call(_oa) if _oa['@class']
@start = Time.from_json(_oa) unless _oa['@class']
elsif (_oa.is_a? Array)
#an array(of hashes hopefully) or scalar
@start = Array.new
_oa.each { | _item |
if ((_item.nil? || _item['@class'].nil?)rescue true)
@start.push Time.from_json(_item)
else
@start.push EnunciateHelpers::LAMB_CLASS_AWARE.call(_item)
end
}
else
@start = _oa
end
end
end
# constructs a CloudCredentials from a (parsed) JSON hash
# constructs a BenchmarkResult from a (parsed) JSON hash
def self.from_json(o)
if o.nil?
return nil
......@@ -2252,6 +2320,8 @@ end
end
end
module Nl
module Uva
......@@ -2270,156 +2340,88 @@ module V1
module External
module Ansible
# (no documentation provided)
class AnsibleOutput < Nl::Uva::Sne::Drip::Drip::Commons::Data::V1::External::OwnedObject
class ScaleRequest < Nl::Uva::Sne::Drip::Drip::Commons::Data::V1::External::OwnedObject
# the host
attr_accessor :host
# the result
attr_accessor :result
# the domain
attr_accessor :cloudDeploymentDomain
#
attr_accessor :vmType
# the provision ID
attr_accessor :provisionID
# the cloudProvider
attr_accessor :cloudProvider
# the scaleTargetID
attr_accessor :scaleTargetID
# the scaleTargetName
attr_accessor :scaleTargetName
# the numOfInstances
attr_accessor :numOfInstances
# the json hash for this AnsibleOutput
# the json hash for this ScaleRequest
def to_jaxb_json_hash
_h = super
_h['host'] = host.to_jaxb_json_hash unless host.nil?
_h['result'] = result.to_jaxb_json_hash unless result.nil?
_h['cloudDeploymentDomain'] = cloudDeploymentDomain.to_jaxb_json_hash unless cloudDeploymentDomain.nil?
_h['vmType'] = vmType.to_jaxb_json_hash unless vmType.nil?
_h['provisionID'] = provisionID.to_jaxb_json_hash unless provisionID.nil?
_h['cloudProvider'] = cloudProvider.to_jaxb_json_hash unless cloudProvider.nil?
_h['scaleTargetID'] = scaleTargetID.to_jaxb_json_hash unless scaleTargetID.nil?
_h['scaleTargetName'] = scaleTargetName.to_jaxb_json_hash unless scaleTargetName.nil?
_h['numOfInstances'] = numOfInstances.to_jaxb_json_hash unless numOfInstances.nil?
return _h
end
#initializes this AnsibleOutput with a json hash
#initializes this ScaleRequest with a json hash
def init_jaxb_json_hash(_o)
super _o
if !_o['host'].nil?
_oa = _o['host']
if(_oa.is_a? Hash)
@host = EnunciateHelpers::LAMB_CLASS_AWARE.call(_oa) if _oa['@class']
@host = String.from_json(_oa) unless _oa['@class']
elsif (_oa.is_a? Array)
#an array(of hashes hopefully) or scalar
@host = Array.new
_oa.each { | _item |
if ((_item.nil? || _item['@class'].nil?)rescue true)
@host.push String.from_json(_item)
else
@host.push EnunciateHelpers::LAMB_CLASS_AWARE.call(_item)
end
}
else
@host = _oa
end
end
if !_o['result'].nil?
_oa = _o['result']
if(_oa.is_a? Hash)
@result = EnunciateHelpers::LAMB_CLASS_AWARE.call(_oa) if _oa['@class']
@result = Nl::Uva::Sne::Drip::Drip::Commons::Data::V1::External::Ansible::AnsibleResult.from_json(_oa) unless _oa['@class']
elsif (_oa.is_a? Array)
#an array(of hashes hopefully) or scalar
@result = Array.new
_oa.each { | _item |
if ((_item.nil? || _item['@class'].nil?)rescue true)
@result.push Nl::Uva::Sne::Drip::Drip::Commons::Data::V1::External::Ansible::AnsibleResult.from_json(_item)
else
@result.push EnunciateHelpers::LAMB_CLASS_AWARE.call(_item)
end
}
else
@result = _oa
end
end
if !_o['cloudDeploymentDomain'].nil?
_oa = _o['cloudDeploymentDomain']
if(_oa.is_a? Hash)
@cloudDeploymentDomain = EnunciateHelpers::LAMB_CLASS_AWARE.call(_oa) if _oa['@class']
@cloudDeploymentDomain = String.from_json(_oa) unless _oa['@class']
elsif (_oa.is_a? Array)
#an array(of hashes hopefully) or scalar
@cloudDeploymentDomain = Array.new
_oa.each { | _item |
if ((_item.nil? || _item['@class'].nil?)rescue true)
@cloudDeploymentDomain.push String.from_json(_item)
else
@cloudDeploymentDomain.push EnunciateHelpers::LAMB_CLASS_AWARE.call(_item)
end
}
else
@cloudDeploymentDomain = _oa
end
end
if !_o['vmType'].nil?
_oa = _o['vmType']
if !_o['scaleTargetID'].nil?
_oa = _o['scaleTargetID']
if(_oa.is_a? Hash)
@vmType = EnunciateHelpers::LAMB_CLASS_AWARE.call(_oa) if _oa['@class']
@vmType = String.from_json(_oa) unless _oa['@class']
@scaleTargetID = EnunciateHelpers::LAMB_CLASS_AWARE.call(_oa) if _oa['@class']
@scaleTargetID = String.from_json(_oa) unless _oa['@class']
elsif (_oa.is_a? Array)
#an array(of hashes hopefully) or scalar
@vmType = Array.new
@scaleTargetID = Array.new
_oa.each { | _item |
if ((_item.nil? || _item['@class'].nil?)rescue true)
@vmType.push String.from_json(_item)
@scaleTargetID.push String.from_json(_item)
else
@vmType.push EnunciateHelpers::LAMB_CLASS_AWARE.call(_item)
@scaleTargetID.push EnunciateHelpers::LAMB_CLASS_AWARE.call(_item)
end
}
else
@vmType = _oa
@scaleTargetID = _oa
end
end
if !_o['provisionID'].nil?
_oa = _o['provisionID']
if !_o['scaleTargetName'].nil?
_oa = _o['scaleTargetName']
if(_oa.is_a? Hash)
@provisionID = EnunciateHelpers::LAMB_CLASS_AWARE.call(_oa) if _oa['@class']
@provisionID = String.from_json(_oa) unless _oa['@class']
@scaleTargetName = EnunciateHelpers::LAMB_CLASS_AWARE.call(_oa) if _oa['@class']
@scaleTargetName = String.from_json(_oa) unless _oa['@class']
elsif (_oa.is_a? Array)
#an array(of hashes hopefully) or scalar
@provisionID = Array.new
@scaleTargetName = Array.new
_oa.each { | _item |
if ((_item.nil? || _item['@class'].nil?)rescue true)
@provisionID.push String.from_json(_item)
@scaleTargetName.push String.from_json(_item)
else
@provisionID.push EnunciateHelpers::LAMB_CLASS_AWARE.call(_item)
@scaleTargetName.push EnunciateHelpers::LAMB_CLASS_AWARE.call(_item)
end
}
else
@provisionID = _oa
@scaleTargetName = _oa
end
end
if !_o['cloudProvider'].nil?
_oa = _o['cloudProvider']
if !_o['numOfInstances'].nil?
_oa = _o['numOfInstances']
if(_oa.is_a? Hash)
@cloudProvider = EnunciateHelpers::LAMB_CLASS_AWARE.call(_oa) if _oa['@class']
@cloudProvider = String.from_json(_oa) unless _oa['@class']
@numOfInstances = EnunciateHelpers::LAMB_CLASS_AWARE.call(_oa) if _oa['@class']
@numOfInstances = Fixnum.from_json(_oa) unless _oa['@class']
elsif (_oa.is_a? Array)
#an array(of hashes hopefully) or scalar
@cloudProvider = Array.new
@numOfInstances = Array.new
_oa.each { | _item |
if ((_item.nil? || _item['@class'].nil?)rescue true)
@cloudProvider.push String.from_json(_item)
@numOfInstances.push Fixnum.from_json(_item)
else
@cloudProvider.push EnunciateHelpers::LAMB_CLASS_AWARE.call(_item)
@numOfInstances.push EnunciateHelpers::LAMB_CLASS_AWARE.call(_item)
end
}
else
@cloudProvider = _oa
@numOfInstances = _oa
end
end
end
# constructs a AnsibleOutput from a (parsed) JSON hash
# constructs a ScaleRequest from a (parsed) JSON hash
def self.from_json(o)
if o.nil?
return nil
......@@ -2449,8 +2451,6 @@ end
end
end
module Nl
module Uva
......
......@@ -81,16 +81,16 @@ class</p>
</thead>
<tbody>
<tr>
<td> <span class="property-name">delta</span>
<td> <span class="property-name">host</span>
</td>
<td> <span class="datatype-reference">number
<td> <span class="datatype-reference">string
</span>
</td>
<td> <span class="property-description"></span>
</td>
</tr>
<tr>
<td> <span class="property-name">cloudDeploymentDomain</span>
<td> <span class="property-name">vmType</span>
</td>
<td> <span class="datatype-reference">string
</span>
......@@ -99,16 +99,16 @@ class</p>
</td>
</tr>
<tr>
<td> <span class="property-name">vmType</span>
<td> <span class="property-name">end</span>
</td>
<td> <span class="datatype-reference">string
<td> <span class="datatype-reference">number
</span>
</td>
<td> <span class="property-description"></span>
</td>
</tr>
<tr>
<td> <span class="property-name">host</span>
<td> <span class="property-name">cloudDeploymentDomain</span>
</td>
<td> <span class="datatype-reference">string
</span>
......@@ -117,7 +117,7 @@ class</p>
</td>
</tr>
<tr>
<td> <span class="property-name">start</span>
<td> <span class="property-name">delta</span>
</td>
<td> <span class="datatype-reference">number
</span>
......@@ -126,7 +126,7 @@ class</p>
</td>
</tr>
<tr>
<td> <span class="property-name">end</span>
<td> <span class="property-name">start</span>
</td>
<td> <span class="datatype-reference">number
</span>
......@@ -167,12 +167,12 @@ No need to set during a POST</span></td>
<p class="lead">Example</p>
<pre class="prettyprint language-js example">{
&quot;delta&quot; : 12345,
&quot;cloudDeploymentDomain&quot; : &quot;us-east-1&quot;,
&quot;vmType&quot; : &quot;...&quot;,
&quot;host&quot; : &quot;147.228.242.58&quot;,
&quot;start&quot; : 12345,
&quot;vmType&quot; : &quot;...&quot;,
&quot;end&quot; : 12345,
&quot;cloudDeploymentDomain&quot; : &quot;us-east-1&quot;,
&quot;delta&quot; : 12345,
&quot;start&quot; : 12345,
&quot;owner&quot; : &quot;user1&quot;,
&quot;id&quot; : &quot;58e3946e0fb4f562d84ba1ad&quot;,
&quot;timestamp&quot; : 1499793079011
......
......@@ -69,7 +69,7 @@ class</p>
<dl class="dl-horizontal">
<dt>Subtypes</dt>
<dd><a href="json_KeyPair.html">KeyPair</a>, <a href="json_AnsibleOutput.html">AnsibleOutput</a>, <a href="json_ScaleRequest.html">ScaleRequest</a>, <a href="json_CloudCredentials.html">CloudCredentials</a>, <a href="json_BenchmarkResult.html">BenchmarkResult</a>, <a href="json_DeployResponse.html">DeployResponse</a>, <a href="json_DRIPLogRecord.html">DRIPLogRecord</a>, <a href="json_ProvisionRequest.html">ProvisionRequest</a>, <a href="json_Script.html">Script</a>, <a href="json_KeyValueHolder.html">KeyValueHolder</a>, <a href="json_DeployRequest.html">DeployRequest</a>, <a href="json_MonitorringMessage.html">MonitorringMessage</a>, <a href="json_ProvisionResponse.html">ProvisionResponse</a></dd>
<dd><a href="json_KeyPair.html">KeyPair</a>, <a href="json_ScaleRequest.html">ScaleRequest</a>, <a href="json_AnsibleOutput.html">AnsibleOutput</a>, <a href="json_BenchmarkResult.html">BenchmarkResult</a>, <a href="json_CloudCredentials.html">CloudCredentials</a>, <a href="json_DeployResponse.html">DeployResponse</a>, <a href="json_DRIPLogRecord.html">DRIPLogRecord</a>, <a href="json_ProvisionRequest.html">ProvisionRequest</a>, <a href="json_Script.html">Script</a>, <a href="json_KeyValueHolder.html">KeyValueHolder</a>, <a href="json_DeployRequest.html">DeployRequest</a>, <a href="json_ProvisionResponse.html">ProvisionResponse</a>, <a href="json_MonitorringMessage.html">MonitorringMessage</a></dd>
</dl>
<table class="table datatype-properties">
......
......@@ -821,18 +821,18 @@ class]]>
<xs:complexContent>
<xs:extension base="ownedObject">
<xs:sequence>
<xs:element name="cloudDeploymentDomain" type="xs:string" minOccurs="0">
</xs:element>
<xs:element name="start" type="xs:dateTime" minOccurs="0">
</xs:element>
<xs:element name="vmType" type="xs:string" minOccurs="0">
</xs:element>
<xs:element name="end" type="xs:dateTime" minOccurs="0">
</xs:element>
<xs:element name="host" type="xs:string" minOccurs="0">
<xs:element name="cloudDeploymentDomain" type="xs:string" minOccurs="0">
</xs:element>
<xs:element name="start" type="xs:dateTime" minOccurs="0">
</xs:element>
<xs:element name="delta" type="xs:dateTime" minOccurs="0">
</xs:element>
<xs:element name="host" type="xs:string" minOccurs="0">
</xs:element>
</xs:sequence>
</xs:extension>
</xs:complexContent>
......
......@@ -144,12 +144,12 @@ Content-Type: application/json
<code class="prettyprint language-js">
[ {
&quot;delta&quot; : 12345,
&quot;cloudDeploymentDomain&quot; : &quot;us-east-1&quot;,
&quot;vmType&quot; : &quot;...&quot;,
&quot;host&quot; : &quot;147.228.242.58&quot;,
&quot;start&quot; : 12345,
&quot;vmType&quot; : &quot;...&quot;,
&quot;end&quot; : 12345,
&quot;cloudDeploymentDomain&quot; : &quot;us-east-1&quot;,
&quot;delta&quot; : 12345,
&quot;start&quot; : 12345,
&quot;owner&quot; : &quot;user1&quot;,
&quot;id&quot; : &quot;58e3946e0fb4f562d84ba1ad&quot;,
&quot;timestamp&quot; : 1499793079011
......@@ -514,12 +514,12 @@ Content-Type: application/json
<code class="prettyprint language-js">
{
&quot;delta&quot; : 12345,
&quot;cloudDeploymentDomain&quot; : &quot;us-east-1&quot;,
&quot;vmType&quot; : &quot;...&quot;,
&quot;host&quot; : &quot;147.228.242.58&quot;,
&quot;start&quot; : 12345,
&quot;vmType&quot; : &quot;...&quot;,
&quot;end&quot; : 12345,
&quot;cloudDeploymentDomain&quot; : &quot;us-east-1&quot;,
&quot;delta&quot; : 12345,
&quot;start&quot; : 12345,
&quot;owner&quot; : &quot;user1&quot;,
&quot;id&quot; : &quot;58e3946e0fb4f562d84ba1ad&quot;,
&quot;timestamp&quot; : 1499793079011
......
......@@ -220,12 +220,12 @@ It is created automatically. No need to set during a POST</span></td>
<p class="lead">Example</p>
<pre class="prettyprint language-xml example">&lt;b-----&gt;
&lt;cloudDeploymentDomain&gt;us-east-1&lt;/cloudDeploymentDomain&gt;
&lt;start&gt;...&lt;/start&gt;
&lt;vmType&gt;...&lt;/vmType&gt;
&lt;end&gt;...&lt;/end&gt;
&lt;host&gt;147.228.242.58&lt;/host&gt;
&lt;cloudDeploymentDomain&gt;us-east-1&lt;/cloudDeploymentDomain&gt;
&lt;start&gt;...&lt;/start&gt;
&lt;delta&gt;...&lt;/delta&gt;
&lt;host&gt;147.228.242.58&lt;/host&gt;
&lt;owner&gt;user1&lt;/owner&gt;
&lt;/b-----&gt;
</pre>
......
......@@ -27,126 +27,61 @@ public class P2PConverter {
List<Object> vmList = Converter.jsonString2List(plannerOutputJson);
String provisionerScalingMode = "fixed";
for (Object element : vmList) {
Map<String, Object> map = null;
if (element instanceof Map) {
map = (Map<String, Object>) element;
} else if (element instanceof String) {
map = Converter.jsonString2Map((String) element);
}
if (map != null && map.containsKey("scaling_mode")) {
String scalingMode = (String) map.get("scaling_mode");
if (!scalingMode.equals("single")) {
provisionerScalingMode = "scaling";
break;
}
}
}
TopTopology topTopology = new TopTopology();
SubTopology subTopology = null;
switch (cloudProvider.trim().toLowerCase()) {
case "ec2":
subTopology = new EC2SubTopology();
break;
case "egi":
subTopology = new EGISubTopology();
break;
default:
Logger.getLogger(P2PConverter.class.getName()).log(Level.WARNING, "The {0} is not supported yet!", cloudProvider);
return null;
}
topTopology.publicKeyPath = null;
topTopology.userName = userName;
topTopology.topologies = new ArrayList<>();
boolean firstVM = true;
SubTopologyInfo sti = new SubTopologyInfo();
String provisionerScalingMode = "fixed";
SubTopology subTopology = createSubTopology(cloudProvider);
sti.cloudProvider = cloudProvider;
sti.topology = UUID.randomUUID().toString();
sti.domain = domainName;
sti.status = "fresh";
sti.tag = provisionerScalingMode;
topTopology.publicKeyPath = null;
topTopology.userName = userName;
if (cloudProvider.trim().toLowerCase().equals("ec2")) {
Subnet s = new Subnet();
s.name = "s1";
s.subnet = "192.168.10.0";
s.netmask = "255.255.255.0";
subTopology.subnets = new ArrayList<>();
subTopology.subnets.add(s);
}
switch (cloudProvider.trim().toLowerCase()) {
case "ec2":
((EC2SubTopology) subTopology).components = new ArrayList<>();
break;
case "egi":
((EGISubTopology) subTopology).components = new ArrayList<>();
break;
default:
Logger.getLogger(P2PConverter.class.getName()).log(Level.WARNING, "The {0} is not supported yet!", cloudProvider);
return null;
}
boolean firstVM = true;
Map<String, SubTopologyInfo> subTopologyInfos = new HashMap<>();
for (Object element : vmList) {
Map<String, Object> map = null;
if (element instanceof Map) {
map = (Map<String, Object>) element;
} else if (element instanceof String) {
map = Converter.jsonString2Map((String) element);
VM vm = createVM(element, cloudProvider, firstVM);
firstVM = false;
if (isScalable(element)) {
sti = new SubTopologyInfo();
subTopology = createSubTopology(cloudProvider);
provisionerScalingMode = "scaling";
sti.cloudProvider = cloudProvider;
sti.topology = UUID.randomUUID().toString();
sti.domain = domainName;
sti.status = "fresh";
sti.tag = provisionerScalingMode;
} else {
for (SubTopologyInfo info : subTopologyInfos.values()) {
if (!info.tag.equals("scaling")) {
sti = info;
subTopology = sti.subTopology;
break;
}
}
}
subTopology = addVMToSubTopology(cloudProvider, vm, subTopology);
VM curVM;
switch (cloudProvider.trim().toLowerCase()) {
case "ec2":
curVM = new EC2VM();
break;
case "egi":
curVM = new EGIVM();
break;
default:
Logger.getLogger(P2PConverter.class.getName()).log(Level.WARNING, "The {0} is not supported yet!", cloudProvider);
return null;
if (cloudProvider.trim().toLowerCase().equals("ec2")) {
Subnet s = new Subnet();
s.name = "s1";
s.subnet = "192.168.10.0";
s.netmask = "255.255.255.0";
subTopology.subnets = new ArrayList<>();
subTopology.subnets.add(s);
}
curVM.name = (String) map.get("name");
curVM.type = (String) map.get("type");
curVM.OStype = ((Map<String, String>) map.get("os")).get("distribution") + " " + ((Map<String, Double>) map.get("os")).get("os_version");
// curVM.clusterType = clusterType;
// curVM.dockers = curValue.getDocker();
curVM.nodeType = getSize((Map<String, String>) map.get("host"), cloudProvider);
sti.subTopology = subTopology;
subTopologyInfos.put(sti.topology, sti);
// Eth eth = new Eth();
// eth.name = "p1";
// eth.subnetName = "s1";
// int hostNum = 10 + vi;
// String priAddress = "192.168.10." + hostNum;
// eth.address = priAddress;
// curVM.ethernetPort = new ArrayList<Eth>();
// curVM.ethernetPort.add(eth);
if (firstVM) {
curVM.role = "master";
firstVM = false;
} else {
curVM.role = "slave";
}
switch (cloudProvider.trim().toLowerCase()) {
case "ec2":
((EC2SubTopology) subTopology).components.add((EC2VM) curVM);
break;
case "egi":
((EGISubTopology) subTopology).components.add((EGIVM) curVM);
break;
default:
Logger.getLogger(P2PConverter.class.getName()).log(Level.WARNING, "The {0} is not supported yet!", cloudProvider);
return null;
}
}
sti.subTopology = subTopology;
topTopology.topologies = new ArrayList<>();
topTopology.topologies.add(sti);
for (SubTopologyInfo info : subTopologyInfos.values()) {
topTopology.topologies.add(info);
}
SimplePlanContainer spc = generateInfo(topTopology);
......@@ -184,4 +119,96 @@ public class P2PConverter {
}
}
private static VM createVM(Object element, String cloudProvider, boolean firstVM) throws JSONException, IOException {
VM curVM;
switch (cloudProvider.trim().toLowerCase()) {
case "ec2":
curVM = new EC2VM();
break;
case "egi":
curVM = new EGIVM();
break;
default:
Logger.getLogger(P2PConverter.class.getName()).log(Level.WARNING, "The {0} is not supported yet!", cloudProvider);
return null;
}
Map<String, Object> map = null;
if (element instanceof Map) {
map = (Map<String, Object>) element;
} else if (element instanceof String) {
map = Converter.jsonString2Map((String) element);
}
curVM.name = (String) map.get("name");
curVM.type = (String) map.get("type");
curVM.OStype = ((Map<String, String>) map.get("os")).get("distribution") + " " + ((Map<String, Double>) map.get("os")).get("os_version");
// curVM.clusterType = clusterType;
// curVM.dockers = curValue.getDocker();
curVM.nodeType = getSize((Map<String, String>) map.get("host"), cloudProvider);
// Eth eth = new Eth();
// eth.name = "p1";
// eth.subnetName = "s1";
// int hostNum = 10 + vi;
// String priAddress = "192.168.10." + hostNum;
// eth.address = priAddress;
// curVM.ethernetPort = new ArrayList<Eth>();
// curVM.ethernetPort.add(eth);
if (firstVM) {
curVM.role = "master";
} else {
curVM.role = "slave";
}
return curVM;
}
private static SubTopology createSubTopology(String cloudProvider) {
SubTopology subTopology;
switch (cloudProvider.trim().toLowerCase()) {
case "ec2":
subTopology = new EC2SubTopology();
((EC2SubTopology) subTopology).components = new ArrayList<>();
break;
case "egi":
subTopology = new EGISubTopology();
((EGISubTopology) subTopology).components = new ArrayList<>();
break;
default:
Logger.getLogger(P2PConverter.class.getName()).log(Level.WARNING, "The {0} is not supported yet!", cloudProvider);
return null;
}
return subTopology;
}
private static SubTopology addVMToSubTopology(String cloudProvider, VM vm, SubTopology subTopology) {
switch (cloudProvider.trim().toLowerCase()) {
case "ec2":
((EC2SubTopology) subTopology).components.add((EC2VM) vm);
break;
case "egi":
((EGISubTopology) subTopology).components.add((EGIVM) vm);
break;
default:
Logger.getLogger(P2PConverter.class.getName()).log(Level.WARNING, "The {0} is not supported yet!", cloudProvider);
// return null;
}
return subTopology;
}
private static boolean isScalable(Object element) throws JSONException, IOException {
Map<String, Object> map = null;
if (element instanceof Map) {
map = (Map<String, Object>) element;
} else if (element instanceof String) {
map = Converter.jsonString2Map((String) element);
}
if (map != null && map.containsKey("scaling_mode")) {
String scalingMode = (String) map.get("scaling_mode");
if (!scalingMode.equals("single")) {
return true;
}
}
return false;
}
}
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment