You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cloudstack.apache.org by ts...@apache.org on 2013/04/21 14:23:29 UTC

[16/17] make the module structure more relevant and simple

http://git-wip-us.apache.org/repos/asf/cloudstack/blob/dd838d72/tools/marvin/marvin/base/Host.py
----------------------------------------------------------------------
diff --git a/tools/marvin/marvin/base/Host.py b/tools/marvin/marvin/base/Host.py
new file mode 100644
index 0000000..4244197
--- /dev/null
+++ b/tools/marvin/marvin/base/Host.py
@@ -0,0 +1,104 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements.  See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership.  The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License.  You may obtain a copy of the License at
+#
+#   http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied.  See the License for the
+# specific language governing permissions and limitations
+# under the License.
+from marvin.base import CloudStackEntity
+from marvin.cloudstackAPI import addHost
+from marvin.cloudstackAPI import listHosts
+from marvin.cloudstackAPI import updateHost
+from marvin.cloudstackAPI import reconnectHost
+from marvin.cloudstackAPI import deleteHost
+from marvin.cloudstackAPI import prepareHostForMaintenance
+from marvin.cloudstackAPI import cancelHostMaintenance
+from marvin.cloudstackAPI import updateHostPassword
+
+class Host(CloudStackEntity.CloudStackEntity):
+
+
+    def __init__(self, items):
+        self.__dict__.update(items)
+
+
+    def add(self, apiclient, username, podid, url, hypervisor, zoneid, password, **kwargs):
+        cmd = addHost.addHostCmd()
+        cmd.id = self.id
+        cmd.hypervisor = hypervisor
+        cmd.password = password
+        cmd.podid = podid
+        cmd.url = url
+        cmd.username = username
+        cmd.zoneid = zoneid
+        [setattr(cmd, key, value) for key,value in kwargs.iteritems()]
+        host = apiclient.addHost(cmd)
+        return host
+
+
+    @classmethod
+    def list(self, apiclient, **kwargs):
+        cmd = listHosts.listHostsCmd()
+        [setattr(cmd, key, value) for key,value in kwargs.iteritems()]
+        host = apiclient.listHosts(cmd)
+        return map(lambda e: Host(e.__dict__), host)
+
+
+    def update(self, apiclient, **kwargs):
+        cmd = updateHost.updateHostCmd()
+        cmd.id = self.id
+        [setattr(cmd, key, value) for key,value in kwargs.iteritems()]
+        host = apiclient.updateHost(cmd)
+        return host
+
+
+    def reconnect(self, apiclient, **kwargs):
+        cmd = reconnectHost.reconnectHostCmd()
+        cmd.id = self.id
+        [setattr(cmd, key, value) for key,value in kwargs.iteritems()]
+        host = apiclient.reconnectHost(cmd)
+        return host
+
+
+    def delete(self, apiclient, **kwargs):
+        cmd = deleteHost.deleteHostCmd()
+        cmd.id = self.id
+        [setattr(cmd, key, value) for key,value in kwargs.iteritems()]
+        host = apiclient.deleteHost(cmd)
+        return host
+
+
+    def prepareMaintenance(self, apiclient, **kwargs):
+        cmd = prepareHostForMaintenance.prepareHostForMaintenanceCmd()
+        cmd.id = self.id
+        [setattr(cmd, key, value) for key,value in kwargs.iteritems()]
+        hostformaintenance = apiclient.prepareHostForMaintenance(cmd)
+        return hostformaintenance
+
+
+    def cancelMaintenance(self, apiclient, **kwargs):
+        cmd = cancelHostMaintenance.cancelHostMaintenanceCmd()
+        cmd.id = self.id
+        [setattr(cmd, key, value) for key,value in kwargs.iteritems()]
+        hostmaintenance = apiclient.cancelHostMaintenance(cmd)
+        return hostmaintenance
+
+
+    def updatePassword(self, apiclient, username, password, **kwargs):
+        cmd = updateHostPassword.updateHostPasswordCmd()
+        cmd.id = self.id
+        cmd.password = password
+        cmd.username = username
+        [setattr(cmd, key, value) for key,value in kwargs.iteritems()]
+        hostpassword = apiclient.updateHostPassword(cmd)
+        return hostpassword
+

http://git-wip-us.apache.org/repos/asf/cloudstack/blob/dd838d72/tools/marvin/marvin/base/HypervisorCapabilities.py
----------------------------------------------------------------------
diff --git a/tools/marvin/marvin/base/HypervisorCapabilities.py b/tools/marvin/marvin/base/HypervisorCapabilities.py
new file mode 100644
index 0000000..6bc52e9
--- /dev/null
+++ b/tools/marvin/marvin/base/HypervisorCapabilities.py
@@ -0,0 +1,42 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements.  See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership.  The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License.  You may obtain a copy of the License at
+#
+#   http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied.  See the License for the
+# specific language governing permissions and limitations
+# under the License.
+from marvin.base import CloudStackEntity
+from marvin.cloudstackAPI import listHypervisorCapabilities
+from marvin.cloudstackAPI import updateHypervisorCapabilities
+
+class HypervisorCapabilities(CloudStackEntity.CloudStackEntity):
+
+
+    def __init__(self, items):
+        self.__dict__.update(items)
+
+
+    @classmethod
+    def list(self, apiclient, **kwargs):
+        cmd = listHypervisorCapabilities.listHypervisorCapabilitiesCmd()
+        [setattr(cmd, key, value) for key,value in kwargs.iteritems()]
+        hypervisorcapabilities = apiclient.listHypervisorCapabilities(cmd)
+        return map(lambda e: HypervisorCapabilities(e.__dict__), hypervisorcapabilities)
+
+
+    def update(self, apiclient, **kwargs):
+        cmd = updateHypervisorCapabilities.updateHypervisorCapabilitiesCmd()
+        cmd.id = self.id
+        [setattr(cmd, key, value) for key,value in kwargs.iteritems()]
+        hypervisorcapabilities = apiclient.updateHypervisorCapabilities(cmd)
+        return hypervisorcapabilities
+

http://git-wip-us.apache.org/repos/asf/cloudstack/blob/dd838d72/tools/marvin/marvin/base/Hypervisors.py
----------------------------------------------------------------------
diff --git a/tools/marvin/marvin/base/Hypervisors.py b/tools/marvin/marvin/base/Hypervisors.py
new file mode 100644
index 0000000..d5fc8da
--- /dev/null
+++ b/tools/marvin/marvin/base/Hypervisors.py
@@ -0,0 +1,33 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements.  See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership.  The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License.  You may obtain a copy of the License at
+#
+#   http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied.  See the License for the
+# specific language governing permissions and limitations
+# under the License.
+from marvin.base import CloudStackEntity
+from marvin.cloudstackAPI import listHypervisors
+
+class Hypervisors(CloudStackEntity.CloudStackEntity):
+
+
+    def __init__(self, items):
+        self.__dict__.update(items)
+
+
+    @classmethod
+    def list(self, apiclient, **kwargs):
+        cmd = listHypervisors.listHypervisorsCmd()
+        [setattr(cmd, key, value) for key,value in kwargs.iteritems()]
+        hypervisors = apiclient.listHypervisors(cmd)
+        return map(lambda e: Hypervisors(e.__dict__), hypervisors)
+

http://git-wip-us.apache.org/repos/asf/cloudstack/blob/dd838d72/tools/marvin/marvin/base/InstanceGroup.py
----------------------------------------------------------------------
diff --git a/tools/marvin/marvin/base/InstanceGroup.py b/tools/marvin/marvin/base/InstanceGroup.py
new file mode 100644
index 0000000..33563cd
--- /dev/null
+++ b/tools/marvin/marvin/base/InstanceGroup.py
@@ -0,0 +1,61 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements.  See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership.  The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License.  You may obtain a copy of the License at
+#
+#   http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied.  See the License for the
+# specific language governing permissions and limitations
+# under the License.
+from marvin.base import CloudStackEntity
+from marvin.cloudstackAPI import createInstanceGroup
+from marvin.cloudstackAPI import listInstanceGroups
+from marvin.cloudstackAPI import updateInstanceGroup
+from marvin.cloudstackAPI import deleteInstanceGroup
+
+class InstanceGroup(CloudStackEntity.CloudStackEntity):
+
+
+    def __init__(self, items):
+        self.__dict__.update(items)
+
+
+    @classmethod
+    def create(cls, apiclient, factory, **kwargs):
+        cmd = createInstanceGroup.createInstanceGroupCmd()
+        [setattr(cmd, factoryKey, factoryValue) for factoryKey, factoryValue in factory.__dict__.iteritems()]
+        [setattr(cmd, key, value) for key,value in kwargs.iteritems()]
+        instancegroup = apiclient.createInstanceGroup(cmd)
+        return InstanceGroup(instancegroup.__dict__)
+
+
+    @classmethod
+    def list(self, apiclient, **kwargs):
+        cmd = listInstanceGroups.listInstanceGroupsCmd()
+        [setattr(cmd, key, value) for key,value in kwargs.iteritems()]
+        instancegroup = apiclient.listInstanceGroups(cmd)
+        return map(lambda e: InstanceGroup(e.__dict__), instancegroup)
+
+
+    def update(self, apiclient, **kwargs):
+        cmd = updateInstanceGroup.updateInstanceGroupCmd()
+        cmd.id = self.id
+        [setattr(cmd, key, value) for key,value in kwargs.iteritems()]
+        instancegroup = apiclient.updateInstanceGroup(cmd)
+        return instancegroup
+
+
+    def delete(self, apiclient, **kwargs):
+        cmd = deleteInstanceGroup.deleteInstanceGroupCmd()
+        cmd.id = self.id
+        [setattr(cmd, key, value) for key,value in kwargs.iteritems()]
+        instancegroup = apiclient.deleteInstanceGroup(cmd)
+        return instancegroup
+

http://git-wip-us.apache.org/repos/asf/cloudstack/blob/dd838d72/tools/marvin/marvin/base/IpAddress.py
----------------------------------------------------------------------
diff --git a/tools/marvin/marvin/base/IpAddress.py b/tools/marvin/marvin/base/IpAddress.py
new file mode 100644
index 0000000..6fdfe1e
--- /dev/null
+++ b/tools/marvin/marvin/base/IpAddress.py
@@ -0,0 +1,50 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements.  See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership.  The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License.  You may obtain a copy of the License at
+#
+#   http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied.  See the License for the
+# specific language governing permissions and limitations
+# under the License.
+from marvin.base import CloudStackEntity
+from marvin.cloudstackAPI import disassociateIpAddress
+from marvin.cloudstackAPI import associateIpAddress
+from marvin.cloudstackAPI import listPublicIpAddresses
+
+class IpAddress(CloudStackEntity.CloudStackEntity):
+
+
+    def __init__(self, items):
+        self.__dict__.update(items)
+
+
+    def disassociate(self, apiclient, **kwargs):
+        cmd = disassociateIpAddress.disassociateIpAddressCmd()
+        cmd.id = self.id
+        [setattr(cmd, key, value) for key,value in kwargs.iteritems()]
+        ipaddress = apiclient.disassociateIpAddress(cmd)
+        return ipaddress
+
+
+    def associate(self, apiclient, **kwargs):
+        cmd = associateIpAddress.associateIpAddressCmd()
+        cmd.id = self.id
+        [setattr(cmd, key, value) for key,value in kwargs.iteritems()]
+        ipaddress = apiclient.associateIpAddress(cmd)
+        return ipaddress
+
+
+    @classmethod
+    def list(self, apiclient, **kwargs):
+        cmd = listPublicIpAddresses.listPublicIpAddressesCmd()
+        [setattr(cmd, key, value) for key,value in kwargs.iteritems()]
+        publicipaddresses = apiclient.listPublicIpAddresses(cmd)
+        return map(lambda e: IpAddress(e.__dict__), publicipaddresses)

http://git-wip-us.apache.org/repos/asf/cloudstack/blob/dd838d72/tools/marvin/marvin/base/IpForwardingRule.py
----------------------------------------------------------------------
diff --git a/tools/marvin/marvin/base/IpForwardingRule.py b/tools/marvin/marvin/base/IpForwardingRule.py
new file mode 100644
index 0000000..ed107b6
--- /dev/null
+++ b/tools/marvin/marvin/base/IpForwardingRule.py
@@ -0,0 +1,52 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements.  See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership.  The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License.  You may obtain a copy of the License at
+#
+#   http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied.  See the License for the
+# specific language governing permissions and limitations
+# under the License.
+from marvin.base import CloudStackEntity
+from marvin.cloudstackAPI import createIpForwardingRule
+from marvin.cloudstackAPI import listIpForwardingRules
+from marvin.cloudstackAPI import deleteIpForwardingRule
+
+class IpForwardingRule(CloudStackEntity.CloudStackEntity):
+
+
+    def __init__(self, items):
+        self.__dict__.update(items)
+
+
+    @classmethod
+    def create(cls, apiclient, factory, **kwargs):
+        cmd = createIpForwardingRule.createIpForwardingRuleCmd()
+        [setattr(cmd, factoryKey, factoryValue) for factoryKey, factoryValue in factory.__dict__.iteritems()]
+        [setattr(cmd, key, value) for key,value in kwargs.iteritems()]
+        ipforwardingrule = apiclient.createIpForwardingRule(cmd)
+        return IpForwardingRule(ipforwardingrule.__dict__)
+
+
+    @classmethod
+    def list(self, apiclient, **kwargs):
+        cmd = listIpForwardingRules.listIpForwardingRulesCmd()
+        [setattr(cmd, key, value) for key,value in kwargs.iteritems()]
+        ipforwardingrule = apiclient.listIpForwardingRules(cmd)
+        return map(lambda e: IpForwardingRule(e.__dict__), ipforwardingrule)
+
+
+    def delete(self, apiclient, **kwargs):
+        cmd = deleteIpForwardingRule.deleteIpForwardingRuleCmd()
+        cmd.id = self.id
+        [setattr(cmd, key, value) for key,value in kwargs.iteritems()]
+        ipforwardingrule = apiclient.deleteIpForwardingRule(cmd)
+        return ipforwardingrule
+

http://git-wip-us.apache.org/repos/asf/cloudstack/blob/dd838d72/tools/marvin/marvin/base/Iso.py
----------------------------------------------------------------------
diff --git a/tools/marvin/marvin/base/Iso.py b/tools/marvin/marvin/base/Iso.py
new file mode 100644
index 0000000..be1e2b0
--- /dev/null
+++ b/tools/marvin/marvin/base/Iso.py
@@ -0,0 +1,105 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements.  See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership.  The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License.  You may obtain a copy of the License at
+#
+#   http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied.  See the License for the
+# specific language governing permissions and limitations
+# under the License.
+from marvin.base import CloudStackEntity
+from marvin.cloudstackAPI import copyIso
+from marvin.cloudstackAPI import registerIso
+from marvin.cloudstackAPI import listIsos
+from marvin.cloudstackAPI import updateIso
+from marvin.cloudstackAPI import attachIso
+from marvin.cloudstackAPI import detachIso
+from marvin.cloudstackAPI import extractIso
+from marvin.cloudstackAPI import deleteIso
+
+class Iso(CloudStackEntity.CloudStackEntity):
+
+
+    def __init__(self, items):
+        self.__dict__.update(items)
+
+
+    def copy(self, apiclient, sourcezoneid, destzoneid, **kwargs):
+        cmd = copyIso.copyIsoCmd()
+        cmd.id = self.id
+        cmd.destzoneid = destzoneid
+        cmd.sourcezoneid = sourcezoneid
+        [setattr(cmd, key, value) for key,value in kwargs.iteritems()]
+        iso = apiclient.copyIso(cmd)
+        return iso
+
+
+    def register(self, apiclient, url, displaytext, name, zoneid, **kwargs):
+        cmd = registerIso.registerIsoCmd()
+        cmd.id = self.id
+        cmd.displaytext = displaytext
+        cmd.name = name
+        cmd.url = url
+        cmd.zoneid = zoneid
+        [setattr(cmd, key, value) for key,value in kwargs.iteritems()]
+        iso = apiclient.registerIso(cmd)
+        return iso
+
+
+    @classmethod
+    def list(self, apiclient, **kwargs):
+        cmd = listIsos.listIsosCmd()
+        [setattr(cmd, key, value) for key,value in kwargs.iteritems()]
+        iso = apiclient.listIsos(cmd)
+        return map(lambda e: Iso(e.__dict__), iso)
+
+
+    def update(self, apiclient, **kwargs):
+        cmd = updateIso.updateIsoCmd()
+        cmd.id = self.id
+        [setattr(cmd, key, value) for key,value in kwargs.iteritems()]
+        iso = apiclient.updateIso(cmd)
+        return iso
+
+
+    def attach(self, apiclient, virtualmachineid, **kwargs):
+        cmd = attachIso.attachIsoCmd()
+        cmd.id = self.id
+        cmd.virtualmachineid = virtualmachineid
+        [setattr(cmd, key, value) for key,value in kwargs.iteritems()]
+        iso = apiclient.attachIso(cmd)
+        return iso
+
+
+    def detach(self, apiclient, virtualmachineid, **kwargs):
+        cmd = detachIso.detachIsoCmd()
+        cmd.id = self.id
+        cmd.virtualmachineid = virtualmachineid
+        [setattr(cmd, key, value) for key,value in kwargs.iteritems()]
+        iso = apiclient.detachIso(cmd)
+        return iso
+
+
+    def extract(self, apiclient, mode, **kwargs):
+        cmd = extractIso.extractIsoCmd()
+        cmd.id = self.id
+        cmd.mode = mode
+        [setattr(cmd, key, value) for key,value in kwargs.iteritems()]
+        iso = apiclient.extractIso(cmd)
+        return iso
+
+
+    def delete(self, apiclient, **kwargs):
+        cmd = deleteIso.deleteIsoCmd()
+        cmd.id = self.id
+        [setattr(cmd, key, value) for key,value in kwargs.iteritems()]
+        iso = apiclient.deleteIso(cmd)
+        return iso
+

http://git-wip-us.apache.org/repos/asf/cloudstack/blob/dd838d72/tools/marvin/marvin/base/IsoPermissions.py
----------------------------------------------------------------------
diff --git a/tools/marvin/marvin/base/IsoPermissions.py b/tools/marvin/marvin/base/IsoPermissions.py
new file mode 100644
index 0000000..1b7c61e
--- /dev/null
+++ b/tools/marvin/marvin/base/IsoPermissions.py
@@ -0,0 +1,42 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements.  See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership.  The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License.  You may obtain a copy of the License at
+#
+#   http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied.  See the License for the
+# specific language governing permissions and limitations
+# under the License.
+from marvin.base import CloudStackEntity
+from marvin.cloudstackAPI import listIsoPermissions
+from marvin.cloudstackAPI import updateIsoPermissions
+
+class IsoPermissions(CloudStackEntity.CloudStackEntity):
+
+
+    def __init__(self, items):
+        self.__dict__.update(items)
+
+
+    @classmethod
+    def list(self, apiclient, **kwargs):
+        cmd = listIsoPermissions.listIsoPermissionsCmd()
+        [setattr(cmd, key, value) for key,value in kwargs.iteritems()]
+        isopermissions = apiclient.listIsoPermissions(cmd)
+        return map(lambda e: IsoPermissions(e.__dict__), isopermissions)
+
+
+    def update(self, apiclient, **kwargs):
+        cmd = updateIsoPermissions.updateIsoPermissionsCmd()
+        cmd.id = self.id
+        [setattr(cmd, key, value) for key,value in kwargs.iteritems()]
+        isopermissions = apiclient.updateIsoPermissions(cmd)
+        return isopermissions
+

http://git-wip-us.apache.org/repos/asf/cloudstack/blob/dd838d72/tools/marvin/marvin/base/LBHealthCheckPolicy.py
----------------------------------------------------------------------
diff --git a/tools/marvin/marvin/base/LBHealthCheckPolicy.py b/tools/marvin/marvin/base/LBHealthCheckPolicy.py
new file mode 100644
index 0000000..6184370
--- /dev/null
+++ b/tools/marvin/marvin/base/LBHealthCheckPolicy.py
@@ -0,0 +1,52 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements.  See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership.  The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License.  You may obtain a copy of the License at
+#
+#   http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied.  See the License for the
+# specific language governing permissions and limitations
+# under the License.
+from marvin.base import CloudStackEntity
+from marvin.cloudstackAPI import createLBHealthCheckPolicy
+from marvin.cloudstackAPI import deleteLBHealthCheckPolicy
+from marvin.cloudstackAPI import listLBHealthCheckPolicies
+
+class LBHealthCheckPolicy(CloudStackEntity.CloudStackEntity):
+
+
+    def __init__(self, items):
+        self.__dict__.update(items)
+
+
+    @classmethod
+    def create(cls, apiclient, factory, **kwargs):
+        cmd = createLBHealthCheckPolicy.createLBHealthCheckPolicyCmd()
+        [setattr(cmd, factoryKey, factoryValue) for factoryKey, factoryValue in factory.__dict__.iteritems()]
+        [setattr(cmd, key, value) for key,value in kwargs.iteritems()]
+        lbhealthcheckpolicy = apiclient.createLBHealthCheckPolicy(cmd)
+        return LBHealthCheckPolicy(lbhealthcheckpolicy.__dict__)
+
+
+    def delete(self, apiclient, **kwargs):
+        cmd = deleteLBHealthCheckPolicy.deleteLBHealthCheckPolicyCmd()
+        cmd.id = self.id
+        [setattr(cmd, key, value) for key,value in kwargs.iteritems()]
+        lbhealthcheckpolicy = apiclient.deleteLBHealthCheckPolicy(cmd)
+        return lbhealthcheckpolicy
+
+
+    @classmethod
+    def list(self, apiclient, lbruleid, **kwargs):
+        cmd = listLBHealthCheckPolicies.listLBHealthCheckPoliciesCmd()
+        cmd.lbruleid = lbruleid
+        [setattr(cmd, key, value) for key,value in kwargs.iteritems()]
+        lbhealthcheckpolicies = apiclient.listLBHealthCheckPolicies(cmd)
+        return map(lambda e: LBHealthCheckPolicy(e.__dict__), lbhealthcheckpolicies)

http://git-wip-us.apache.org/repos/asf/cloudstack/blob/dd838d72/tools/marvin/marvin/base/LBStickinessPolicy.py
----------------------------------------------------------------------
diff --git a/tools/marvin/marvin/base/LBStickinessPolicy.py b/tools/marvin/marvin/base/LBStickinessPolicy.py
new file mode 100644
index 0000000..2a70fc2
--- /dev/null
+++ b/tools/marvin/marvin/base/LBStickinessPolicy.py
@@ -0,0 +1,55 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements.  See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership.  The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License.  You may obtain a copy of the License at
+#
+#   http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied.  See the License for the
+# specific language governing permissions and limitations
+# under the License.
+from marvin.base import CloudStackEntity
+from marvin.cloudstackAPI import createLBStickinessPolicy
+from marvin.cloudstackAPI import deleteLBStickinessPolicy
+from marvin.cloudstackAPI import listLBStickinessPolicies
+
+class LBStickinessPolicy(CloudStackEntity.CloudStackEntity):
+
+
+    def __init__(self, items):
+        self.__dict__.update(items)
+
+
+    @classmethod
+    def create(cls, apiclient, factory, **kwargs):
+        cmd = createLBStickinessPolicy.createLBStickinessPolicyCmd()
+        [setattr(cmd, factoryKey, factoryValue) for factoryKey, factoryValue in factory.__dict__.iteritems()]
+        [setattr(cmd, key, value) for key,value in kwargs.iteritems()]
+        lbstickinesspolicy = apiclient.createLBStickinessPolicy(cmd)
+        return LBStickinessPolicy(lbstickinesspolicy.__dict__)
+
+
+    def delete(self, apiclient, id, **kwargs):
+        cmd = deleteLBStickinessPolicy.deleteLBStickinessPolicyCmd()
+        cmd.id = self.id
+        
+        [setattr(cmd, key, value) for key,value in kwargs.iteritems()]
+        lbstickinesspolicy = apiclient.deleteLBStickinessPolicy(cmd)
+        return lbstickinesspolicy
+
+
+    @classmethod
+    def list(self, apiclient, lbruleid, **kwargs):
+        cmd = listLBStickinessPolicies.listLBStickinessPoliciesCmd()
+        cmd.lbruleid = lbruleid
+        [setattr(cmd, key, value) for key,value in kwargs.iteritems()]
+        lbstickinesspolicies = apiclient.listLBStickinessPolicies(cmd)
+        return map(lambda e: LBStickinessPolicy(e.__dict__), lbstickinesspolicies)
+
+

http://git-wip-us.apache.org/repos/asf/cloudstack/blob/dd838d72/tools/marvin/marvin/base/Ldap.py
----------------------------------------------------------------------
diff --git a/tools/marvin/marvin/base/Ldap.py b/tools/marvin/marvin/base/Ldap.py
new file mode 100644
index 0000000..b035aa5
--- /dev/null
+++ b/tools/marvin/marvin/base/Ldap.py
@@ -0,0 +1,42 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements.  See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership.  The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License.  You may obtain a copy of the License at
+#
+#   http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied.  See the License for the
+# specific language governing permissions and limitations
+# under the License.
+from marvin.base import CloudStackEntity
+from marvin.cloudstackAPI import ldapRemove
+from marvin.cloudstackAPI import ldapConfig
+
+class Ldap(CloudStackEntity.CloudStackEntity):
+
+
+    def __init__(self, items):
+        self.__dict__.update(items)
+
+
+    def config(self, apiclient, **kwargs):
+        cmd = ldapConfig.ldapConfigCmd()
+        cmd.id = self.id
+        [setattr(cmd, key, value) for key,value in kwargs.iteritems()]
+        config = apiclient.ldapConfig(cmd)
+        return config
+
+
+    def remove(self, apiclient, **kwargs):
+        cmd = ldapRemove.ldapRemoveCmd()
+        cmd.id = self.id
+        [setattr(cmd, key, value) for key,value in kwargs.iteritems()]
+        remove = apiclient.ldapRemove(cmd)
+        return remove
+

http://git-wip-us.apache.org/repos/asf/cloudstack/blob/dd838d72/tools/marvin/marvin/base/LoadBalancerRule.py
----------------------------------------------------------------------
diff --git a/tools/marvin/marvin/base/LoadBalancerRule.py b/tools/marvin/marvin/base/LoadBalancerRule.py
new file mode 100644
index 0000000..bb48135
--- /dev/null
+++ b/tools/marvin/marvin/base/LoadBalancerRule.py
@@ -0,0 +1,93 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements.  See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership.  The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License.  You may obtain a copy of the License at
+#
+#   http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied.  See the License for the
+# specific language governing permissions and limitations
+# under the License.
+from marvin.base import CloudStackEntity
+from marvin.cloudstackAPI import createLoadBalancerRule
+from marvin.cloudstackAPI import listLoadBalancerRules
+from marvin.cloudstackAPI import updateLoadBalancerRule
+from marvin.cloudstackAPI import deleteLoadBalancerRule
+from marvin.cloudstackAPI import removeFromLoadBalancerRule
+from marvin.cloudstackAPI import listLoadBalancerRuleInstances
+from marvin.cloudstackAPI import assignToLoadBalancerRule
+
+class LoadBalancerRule(CloudStackEntity.CloudStackEntity):
+
+
+    def __init__(self, items):
+        self.__dict__.update(items)
+
+
+    @classmethod
+    def create(cls, apiclient, factory, **kwargs):
+        cmd = createLoadBalancerRule.createLoadBalancerRuleCmd()
+        [setattr(cmd, factoryKey, factoryValue) for factoryKey, factoryValue in factory.__dict__.iteritems()]
+        [setattr(cmd, key, value) for key,value in kwargs.iteritems()]
+        loadbalancerrule = apiclient.createLoadBalancerRule(cmd)
+        return LoadBalancerRule(loadbalancerrule.__dict__)
+
+
+    @classmethod
+    def list(self, apiclient, **kwargs):
+        cmd = listLoadBalancerRules.listLoadBalancerRulesCmd()
+        [setattr(cmd, key, value) for key,value in kwargs.iteritems()]
+        loadbalancerrule = apiclient.listLoadBalancerRules(cmd)
+        return map(lambda e: LoadBalancerRule(e.__dict__), loadbalancerrule)
+
+
+    def update(self, apiclient, **kwargs):
+        cmd = updateLoadBalancerRule.updateLoadBalancerRuleCmd()
+        cmd.id = self.id
+        [setattr(cmd, key, value) for key,value in kwargs.iteritems()]
+        loadbalancerrule = apiclient.updateLoadBalancerRule(cmd)
+        return loadbalancerrule
+
+
+    def delete(self, apiclient, **kwargs):
+        cmd = deleteLoadBalancerRule.deleteLoadBalancerRuleCmd()
+        cmd.id = self.id
+        [setattr(cmd, key, value) for key,value in kwargs.iteritems()]
+        loadbalancerrule = apiclient.deleteLoadBalancerRule(cmd)
+        return loadbalancerrule
+
+
+    def remove(self, apiclient, virtualmachineids, **kwargs):
+        cmd = removeFromLoadBalancerRule.removeFromLoadBalancerRuleCmd()
+        cmd.id = self.id
+        cmd.virtualmachineids = virtualmachineids
+        [setattr(cmd, key, value) for key,value in kwargs.iteritems()]
+        fromloadbalancerrule = apiclient.removeFromLoadBalancerRule(cmd)
+        return fromloadbalancerrule
+
+
+    def assign(self, apiclient, virtualmachineids, **kwargs):
+        cmd = assignToLoadBalancerRule.assignToLoadBalancerRuleCmd()
+        cmd.id = self.id
+        cmd.virtualmachineids = virtualmachineids
+        [setattr(cmd, key, value) for key,value in kwargs.iteritems()]
+        toloadbalancerrule = apiclient.assignToLoadBalancerRule(cmd)
+        return toloadbalancerrule
+
+
+    @classmethod
+    def listInstances(self, apiclient, **kwargs):
+        cmd = listLoadBalancerRuleInstances.listLoadBalancerRuleInstancesCmd()
+        cmd.id = self.id
+        [setattr(cmd, key, value) for key,value in kwargs.iteritems()]
+        loadbalancerruleinstances = apiclient.listLoadBalancerRuleInstances(cmd)
+        return map(lambda e: LoadBalancerRule(e.__dict__), loadbalancerruleinstances)
+
+
+

http://git-wip-us.apache.org/repos/asf/cloudstack/blob/dd838d72/tools/marvin/marvin/base/Network.py
----------------------------------------------------------------------
diff --git a/tools/marvin/marvin/base/Network.py b/tools/marvin/marvin/base/Network.py
new file mode 100644
index 0000000..c3fc32c
--- /dev/null
+++ b/tools/marvin/marvin/base/Network.py
@@ -0,0 +1,70 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements.  See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership.  The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License.  You may obtain a copy of the License at
+#
+#   http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied.  See the License for the
+# specific language governing permissions and limitations
+# under the License.
+from marvin.base import CloudStackEntity
+from marvin.cloudstackAPI import createNetwork
+from marvin.cloudstackAPI import listNetworks
+from marvin.cloudstackAPI import updateNetwork
+from marvin.cloudstackAPI import restartNetwork
+from marvin.cloudstackAPI import deleteNetwork
+
+class Network(CloudStackEntity.CloudStackEntity):
+
+
+    def __init__(self, items):
+        self.__dict__.update(items)
+
+
+    @classmethod
+    def create(cls, apiclient, factory, **kwargs):
+        cmd = createNetwork.createNetworkCmd()
+        [setattr(cmd, factoryKey, factoryValue) for factoryKey, factoryValue in factory.__dict__.iteritems()]
+        [setattr(cmd, key, value) for key,value in kwargs.iteritems()]
+        network = apiclient.createNetwork(cmd)
+        return Network(network.__dict__)
+
+
+    @classmethod
+    def list(self, apiclient, **kwargs):
+        cmd = listNetworks.listNetworksCmd()
+        [setattr(cmd, key, value) for key,value in kwargs.iteritems()]
+        network = apiclient.listNetworks(cmd)
+        return map(lambda e: Network(e.__dict__), network)
+
+
+    def update(self, apiclient, **kwargs):
+        cmd = updateNetwork.updateNetworkCmd()
+        cmd.id = self.id
+        [setattr(cmd, key, value) for key,value in kwargs.iteritems()]
+        network = apiclient.updateNetwork(cmd)
+        return network
+
+
+    def restart(self, apiclient, **kwargs):
+        cmd = restartNetwork.restartNetworkCmd()
+        cmd.id = self.id
+        [setattr(cmd, key, value) for key,value in kwargs.iteritems()]
+        network = apiclient.restartNetwork(cmd)
+        return network
+
+
+    def delete(self, apiclient, **kwargs):
+        cmd = deleteNetwork.deleteNetworkCmd()
+        cmd.id = self.id
+        [setattr(cmd, key, value) for key,value in kwargs.iteritems()]
+        network = apiclient.deleteNetwork(cmd)
+        return network
+

http://git-wip-us.apache.org/repos/asf/cloudstack/blob/dd838d72/tools/marvin/marvin/base/NetworkACL.py
----------------------------------------------------------------------
diff --git a/tools/marvin/marvin/base/NetworkACL.py b/tools/marvin/marvin/base/NetworkACL.py
new file mode 100644
index 0000000..fc29110
--- /dev/null
+++ b/tools/marvin/marvin/base/NetworkACL.py
@@ -0,0 +1,52 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements.  See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership.  The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License.  You may obtain a copy of the License at
+#
+#   http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied.  See the License for the
+# specific language governing permissions and limitations
+# under the License.
+from marvin.base import CloudStackEntity
+from marvin.cloudstackAPI import createNetworkACL
+from marvin.cloudstackAPI import listNetworkACLs
+from marvin.cloudstackAPI import deleteNetworkACL
+
+class NetworkACL(CloudStackEntity.CloudStackEntity):
+
+
+    def __init__(self, items):
+        self.__dict__.update(items)
+
+
+    @classmethod
+    def create(cls, apiclient, factory, **kwargs):
+        cmd = createNetworkACL.createNetworkACLCmd()
+        [setattr(cmd, factoryKey, factoryValue) for factoryKey, factoryValue in factory.__dict__.iteritems()]
+        [setattr(cmd, key, value) for key,value in kwargs.iteritems()]
+        networkacl = apiclient.createNetworkACL(cmd)
+        return NetworkACL(networkacl.__dict__)
+
+
+    @classmethod
+    def list(self, apiclient, **kwargs):
+        cmd = listNetworkACLs.listNetworkACLsCmd()
+        [setattr(cmd, key, value) for key,value in kwargs.iteritems()]
+        networkacl = apiclient.listNetworkACLs(cmd)
+        return map(lambda e: NetworkACL(e.__dict__), networkacl)
+
+
+    def delete(self, apiclient, **kwargs):
+        cmd = deleteNetworkACL.deleteNetworkACLCmd()
+        cmd.id = self.id
+        [setattr(cmd, key, value) for key,value in kwargs.iteritems()]
+        networkacl = apiclient.deleteNetworkACL(cmd)
+        return networkacl
+

http://git-wip-us.apache.org/repos/asf/cloudstack/blob/dd838d72/tools/marvin/marvin/base/NetworkDevice.py
----------------------------------------------------------------------
diff --git a/tools/marvin/marvin/base/NetworkDevice.py b/tools/marvin/marvin/base/NetworkDevice.py
new file mode 100644
index 0000000..1afc077
--- /dev/null
+++ b/tools/marvin/marvin/base/NetworkDevice.py
@@ -0,0 +1,51 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements.  See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership.  The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License.  You may obtain a copy of the License at
+#
+#   http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied.  See the License for the
+# specific language governing permissions and limitations
+# under the License.
+from marvin.base import CloudStackEntity
+from marvin.cloudstackAPI import addNetworkDevice
+from marvin.cloudstackAPI import listNetworkDevice
+from marvin.cloudstackAPI import deleteNetworkDevice
+
+class NetworkDevice(CloudStackEntity.CloudStackEntity):
+
+
+    def __init__(self, items):
+        self.__dict__.update(items)
+
+
+    def add(self, apiclient, **kwargs):
+        cmd = addNetworkDevice.addNetworkDeviceCmd()
+        cmd.id = self.id
+        [setattr(cmd, key, value) for key,value in kwargs.iteritems()]
+        networkdevice = apiclient.addNetworkDevice(cmd)
+        return networkdevice
+
+
+    @classmethod
+    def list(self, apiclient, **kwargs):
+        cmd = listNetworkDevice.listNetworkDeviceCmd()
+        [setattr(cmd, key, value) for key,value in kwargs.iteritems()]
+        networkdevice = apiclient.listNetworkDevice(cmd)
+        return map(lambda e: NetworkDevice(e.__dict__), networkdevice)
+
+
+    def delete(self, apiclient, **kwargs):
+        cmd = deleteNetworkDevice.deleteNetworkDeviceCmd()
+        cmd.id = self.id
+        [setattr(cmd, key, value) for key,value in kwargs.iteritems()]
+        networkdevice = apiclient.deleteNetworkDevice(cmd)
+        return networkdevice
+

http://git-wip-us.apache.org/repos/asf/cloudstack/blob/dd838d72/tools/marvin/marvin/base/NetworkOffering.py
----------------------------------------------------------------------
diff --git a/tools/marvin/marvin/base/NetworkOffering.py b/tools/marvin/marvin/base/NetworkOffering.py
new file mode 100644
index 0000000..9ca0a55
--- /dev/null
+++ b/tools/marvin/marvin/base/NetworkOffering.py
@@ -0,0 +1,61 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements.  See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership.  The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License.  You may obtain a copy of the License at
+#
+#   http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied.  See the License for the
+# specific language governing permissions and limitations
+# under the License.
+from marvin.base import CloudStackEntity
+from marvin.cloudstackAPI import createNetworkOffering
+from marvin.cloudstackAPI import listNetworkOfferings
+from marvin.cloudstackAPI import updateNetworkOffering
+from marvin.cloudstackAPI import deleteNetworkOffering
+
+class NetworkOffering(CloudStackEntity.CloudStackEntity):
+
+
+    def __init__(self, items):
+        self.__dict__.update(items)
+
+
+    @classmethod
+    def create(cls, apiclient, factory, **kwargs):
+        cmd = createNetworkOffering.createNetworkOfferingCmd()
+        [setattr(cmd, factoryKey, factoryValue) for factoryKey, factoryValue in factory.__dict__.iteritems()]
+        [setattr(cmd, key, value) for key,value in kwargs.iteritems()]
+        networkoffering = apiclient.createNetworkOffering(cmd)
+        return NetworkOffering(networkoffering.__dict__)
+
+
+    @classmethod
+    def list(self, apiclient, **kwargs):
+        cmd = listNetworkOfferings.listNetworkOfferingsCmd()
+        [setattr(cmd, key, value) for key,value in kwargs.iteritems()]
+        networkoffering = apiclient.listNetworkOfferings(cmd)
+        return map(lambda e: NetworkOffering(e.__dict__), networkoffering)
+
+
+    def update(self, apiclient, **kwargs):
+        cmd = updateNetworkOffering.updateNetworkOfferingCmd()
+        cmd.id = self.id
+        [setattr(cmd, key, value) for key,value in kwargs.iteritems()]
+        networkoffering = apiclient.updateNetworkOffering(cmd)
+        return networkoffering
+
+
+    def delete(self, apiclient, **kwargs):
+        cmd = deleteNetworkOffering.deleteNetworkOfferingCmd()
+        cmd.id = self.id
+        [setattr(cmd, key, value) for key,value in kwargs.iteritems()]
+        networkoffering = apiclient.deleteNetworkOffering(cmd)
+        return networkoffering
+

http://git-wip-us.apache.org/repos/asf/cloudstack/blob/dd838d72/tools/marvin/marvin/base/NetworkServiceProvider.py
----------------------------------------------------------------------
diff --git a/tools/marvin/marvin/base/NetworkServiceProvider.py b/tools/marvin/marvin/base/NetworkServiceProvider.py
new file mode 100644
index 0000000..3be84db
--- /dev/null
+++ b/tools/marvin/marvin/base/NetworkServiceProvider.py
@@ -0,0 +1,62 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements.  See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership.  The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License.  You may obtain a copy of the License at
+#
+#   http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied.  See the License for the
+# specific language governing permissions and limitations
+# under the License.
+from marvin.base import CloudStackEntity
+from marvin.cloudstackAPI import addNetworkServiceProvider
+from marvin.cloudstackAPI import listNetworkServiceProviders
+from marvin.cloudstackAPI import updateNetworkServiceProvider
+from marvin.cloudstackAPI import deleteNetworkServiceProvider
+
+class NetworkServiceProvider(CloudStackEntity.CloudStackEntity):
+
+
+    def __init__(self, items):
+        self.__dict__.update(items)
+
+
+    def add(self, apiclient, physicalnetworkid, name, **kwargs):
+        cmd = addNetworkServiceProvider.addNetworkServiceProviderCmd()
+        cmd.id = self.id
+        cmd.name = name
+        cmd.physicalnetworkid = physicalnetworkid
+        [setattr(cmd, key, value) for key,value in kwargs.iteritems()]
+        networkserviceprovider = apiclient.addNetworkServiceProvider(cmd)
+        return networkserviceprovider
+
+
+    @classmethod
+    def list(self, apiclient, **kwargs):
+        cmd = listNetworkServiceProviders.listNetworkServiceProvidersCmd()
+        [setattr(cmd, key, value) for key,value in kwargs.iteritems()]
+        networkserviceprovider = apiclient.listNetworkServiceProviders(cmd)
+        return map(lambda e: NetworkServiceProvider(e.__dict__), networkserviceprovider)
+
+
+    def update(self, apiclient, **kwargs):
+        cmd = updateNetworkServiceProvider.updateNetworkServiceProviderCmd()
+        cmd.id = self.id
+        [setattr(cmd, key, value) for key,value in kwargs.iteritems()]
+        networkserviceprovider = apiclient.updateNetworkServiceProvider(cmd)
+        return networkserviceprovider
+
+
+    def delete(self, apiclient, **kwargs):
+        cmd = deleteNetworkServiceProvider.deleteNetworkServiceProviderCmd()
+        cmd.id = self.id
+        [setattr(cmd, key, value) for key,value in kwargs.iteritems()]
+        networkserviceprovider = apiclient.deleteNetworkServiceProvider(cmd)
+        return networkserviceprovider
+

http://git-wip-us.apache.org/repos/asf/cloudstack/blob/dd838d72/tools/marvin/marvin/base/Nic.py
----------------------------------------------------------------------
diff --git a/tools/marvin/marvin/base/Nic.py b/tools/marvin/marvin/base/Nic.py
new file mode 100644
index 0000000..f25d523
--- /dev/null
+++ b/tools/marvin/marvin/base/Nic.py
@@ -0,0 +1,56 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements.  See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership.  The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License.  You may obtain a copy of the License at
+#
+#   http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied.  See the License for the
+# specific language governing permissions and limitations
+# under the License.
+from marvin.base import CloudStackEntity
+from marvin.cloudstackAPI import listNics
+from marvin.cloudstackAPI import addIpToNic
+from marvin.cloudstackAPI import removeIpFromNic
+
+class Nic(CloudStackEntity.CloudStackEntity):
+
+
+    def __init__(self, items):
+        self.__dict__.update(items)
+
+
+    @classmethod
+    def list(self, apiclient, virtualmachineid, **kwargs):
+        cmd = listNics.listNicsCmd()
+        cmd.virtualmachineid = virtualmachineid
+        [setattr(cmd, key, value) for key,value in kwargs.iteritems()]
+        nics = apiclient.listNics(cmd)
+        return map(lambda e: Nic(e.__dict__), nics)
+
+
+    def add_ip(self, apiclient, **kwargs):
+        cmd = addIpToNic.addIpToNicCmd()
+        cmd.nicid = self.id
+        [setattr(cmd, key, value) for key,value in kwargs.iteritems()]
+        iptonic = apiclient.addIpToNic(cmd)
+        return iptonic
+
+
+    def remove_ip(self, apiclient, **kwargs):
+        cmd = removeIpFromNic.removeIpFromNicCmd()
+        cmd.id = self.id
+        [setattr(cmd, key, value) for key,value in kwargs.iteritems()]
+        ipfromnic = apiclient.removeIpFromNic(cmd)
+        return ipfromnic
+
+
+
+
+

http://git-wip-us.apache.org/repos/asf/cloudstack/blob/dd838d72/tools/marvin/marvin/base/NiciraNvpDevice.py
----------------------------------------------------------------------
diff --git a/tools/marvin/marvin/base/NiciraNvpDevice.py b/tools/marvin/marvin/base/NiciraNvpDevice.py
new file mode 100644
index 0000000..f54be0f
--- /dev/null
+++ b/tools/marvin/marvin/base/NiciraNvpDevice.py
@@ -0,0 +1,66 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements.  See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership.  The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License.  You may obtain a copy of the License at
+#
+#   http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied.  See the License for the
+# specific language governing permissions and limitations
+# under the License.
+from marvin.base import CloudStackEntity
+from marvin.cloudstackAPI import addNiciraNvpDevice
+from marvin.cloudstackAPI import listNiciraNvpDevices
+from marvin.cloudstackAPI import deleteNiciraNvpDevice
+from marvin.cloudstackAPI import listNiciraNvpDeviceNetworks
+
+class NiciraNvpDevice(CloudStackEntity.CloudStackEntity):
+
+
+    def __init__(self, items):
+        self.__dict__.update(items)
+
+
+    def add(self, apiclient, username, physicalnetworkid, password, hostname, transportzoneuuid, **kwargs):
+        cmd = addNiciraNvpDevice.addNiciraNvpDeviceCmd()
+        cmd.id = self.id
+        cmd.hostname = hostname
+        cmd.password = password
+        cmd.physicalnetworkid = physicalnetworkid
+        cmd.transportzoneuuid = transportzoneuuid
+        cmd.username = username
+        [setattr(cmd, key, value) for key,value in kwargs.iteritems()]
+        niciranvpdevice = apiclient.addNiciraNvpDevice(cmd)
+        return niciranvpdevice
+
+
+    @classmethod
+    def list(self, apiclient, **kwargs):
+        cmd = listNiciraNvpDevices.listNiciraNvpDevicesCmd()
+        [setattr(cmd, key, value) for key,value in kwargs.iteritems()]
+        niciranvpdevice = apiclient.listNiciraNvpDevices(cmd)
+        return map(lambda e: NiciraNvpDevice(e.__dict__), niciranvpdevice)
+
+
+    def delete(self, apiclient, nvpdeviceid, **kwargs):
+        cmd = deleteNiciraNvpDevice.deleteNiciraNvpDeviceCmd()
+        cmd.id = self.id
+        cmd.nvpdeviceid = nvpdeviceid
+        [setattr(cmd, key, value) for key,value in kwargs.iteritems()]
+        niciranvpdevice = apiclient.deleteNiciraNvpDevice(cmd)
+        return niciranvpdevice
+
+    @classmethod
+    def listNetworks(self, apiclient, nvpdeviceid, **kwargs):
+        cmd = listNiciraNvpDeviceNetworks.listNiciraNvpDeviceNetworksCmd()
+        cmd.nvpdeviceid = nvpdeviceid
+        [setattr(cmd, key, value) for key,value in kwargs.iteritems()]
+        niciranvpdevicenetworks = apiclient.listNiciraNvpDeviceNetworks(cmd)
+        return map(lambda e: NiciraNvpDevice(e.__dict__), niciranvpdevicenetworks)
+

http://git-wip-us.apache.org/repos/asf/cloudstack/blob/dd838d72/tools/marvin/marvin/base/OsCategories.py
----------------------------------------------------------------------
diff --git a/tools/marvin/marvin/base/OsCategories.py b/tools/marvin/marvin/base/OsCategories.py
new file mode 100644
index 0000000..9ae679c
--- /dev/null
+++ b/tools/marvin/marvin/base/OsCategories.py
@@ -0,0 +1,33 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements.  See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership.  The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License.  You may obtain a copy of the License at
+#
+#   http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied.  See the License for the
+# specific language governing permissions and limitations
+# under the License.
+from marvin.base import CloudStackEntity
+from marvin.cloudstackAPI import listOsCategories
+
+class OsCategories(CloudStackEntity.CloudStackEntity):
+
+
+    def __init__(self, items):
+        self.__dict__.update(items)
+
+
+    @classmethod
+    def list(self, apiclient, **kwargs):
+        cmd = listOsCategories.listOsCategoriesCmd()
+        [setattr(cmd, key, value) for key,value in kwargs.iteritems()]
+        oscategories = apiclient.listOsCategories(cmd)
+        return map(lambda e: OsCategories(e.__dict__), oscategories)
+

http://git-wip-us.apache.org/repos/asf/cloudstack/blob/dd838d72/tools/marvin/marvin/base/OsTypes.py
----------------------------------------------------------------------
diff --git a/tools/marvin/marvin/base/OsTypes.py b/tools/marvin/marvin/base/OsTypes.py
new file mode 100644
index 0000000..52484d2
--- /dev/null
+++ b/tools/marvin/marvin/base/OsTypes.py
@@ -0,0 +1,33 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements.  See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership.  The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License.  You may obtain a copy of the License at
+#
+#   http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied.  See the License for the
+# specific language governing permissions and limitations
+# under the License.
+from marvin.base import CloudStackEntity
+from marvin.cloudstackAPI import listOsTypes
+
+class OsTypes(CloudStackEntity.CloudStackEntity):
+
+
+    def __init__(self, items):
+        self.__dict__.update(items)
+
+
+    @classmethod
+    def list(self, apiclient, **kwargs):
+        cmd = listOsTypes.listOsTypesCmd()
+        [setattr(cmd, key, value) for key,value in kwargs.iteritems()]
+        ostypes = apiclient.listOsTypes(cmd)
+        return map(lambda e: OsTypes(e.__dict__), ostypes)
+

http://git-wip-us.apache.org/repos/asf/cloudstack/blob/dd838d72/tools/marvin/marvin/base/PhysicalNetwork.py
----------------------------------------------------------------------
diff --git a/tools/marvin/marvin/base/PhysicalNetwork.py b/tools/marvin/marvin/base/PhysicalNetwork.py
new file mode 100644
index 0000000..f87d2f9
--- /dev/null
+++ b/tools/marvin/marvin/base/PhysicalNetwork.py
@@ -0,0 +1,61 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements.  See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership.  The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License.  You may obtain a copy of the License at
+#
+#   http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied.  See the License for the
+# specific language governing permissions and limitations
+# under the License.
+from marvin.base import CloudStackEntity
+from marvin.cloudstackAPI import createPhysicalNetwork
+from marvin.cloudstackAPI import listPhysicalNetworks
+from marvin.cloudstackAPI import updatePhysicalNetwork
+from marvin.cloudstackAPI import deletePhysicalNetwork
+
+class PhysicalNetwork(CloudStackEntity.CloudStackEntity):
+
+
+    def __init__(self, items):
+        self.__dict__.update(items)
+
+
+    @classmethod
+    def create(cls, apiclient, factory, **kwargs):
+        cmd = createPhysicalNetwork.createPhysicalNetworkCmd()
+        [setattr(cmd, factoryKey, factoryValue) for factoryKey, factoryValue in factory.__dict__.iteritems()]
+        [setattr(cmd, key, value) for key,value in kwargs.iteritems()]
+        physicalnetwork = apiclient.createPhysicalNetwork(cmd)
+        return PhysicalNetwork(physicalnetwork.__dict__)
+
+
+    @classmethod
+    def list(self, apiclient, **kwargs):
+        cmd = listPhysicalNetworks.listPhysicalNetworksCmd()
+        [setattr(cmd, key, value) for key,value in kwargs.iteritems()]
+        physicalnetwork = apiclient.listPhysicalNetworks(cmd)
+        return map(lambda e: PhysicalNetwork(e.__dict__), physicalnetwork)
+
+
+    def update(self, apiclient, **kwargs):
+        cmd = updatePhysicalNetwork.updatePhysicalNetworkCmd()
+        cmd.id = self.id
+        [setattr(cmd, key, value) for key,value in kwargs.iteritems()]
+        physicalnetwork = apiclient.updatePhysicalNetwork(cmd)
+        return physicalnetwork
+
+
+    def delete(self, apiclient, **kwargs):
+        cmd = deletePhysicalNetwork.deletePhysicalNetworkCmd()
+        cmd.id = self.id
+        [setattr(cmd, key, value) for key,value in kwargs.iteritems()]
+        physicalnetwork = apiclient.deletePhysicalNetwork(cmd)
+        return physicalnetwork
+

http://git-wip-us.apache.org/repos/asf/cloudstack/blob/dd838d72/tools/marvin/marvin/base/Pod.py
----------------------------------------------------------------------
diff --git a/tools/marvin/marvin/base/Pod.py b/tools/marvin/marvin/base/Pod.py
new file mode 100644
index 0000000..6171cc9
--- /dev/null
+++ b/tools/marvin/marvin/base/Pod.py
@@ -0,0 +1,61 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements.  See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership.  The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License.  You may obtain a copy of the License at
+#
+#   http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied.  See the License for the
+# specific language governing permissions and limitations
+# under the License.
+from marvin.base import CloudStackEntity
+from marvin.cloudstackAPI import createPod
+from marvin.cloudstackAPI import listPods
+from marvin.cloudstackAPI import updatePod
+from marvin.cloudstackAPI import deletePod
+
+class Pod(CloudStackEntity.CloudStackEntity):
+
+
+    def __init__(self, items):
+        self.__dict__.update(items)
+
+
+    @classmethod
+    def create(cls, apiclient, factory, **kwargs):
+        cmd = createPod.createPodCmd()
+        [setattr(cmd, factoryKey, factoryValue) for factoryKey, factoryValue in factory.__dict__.iteritems()]
+        [setattr(cmd, key, value) for key,value in kwargs.iteritems()]
+        pod = apiclient.createPod(cmd)
+        return Pod(pod.__dict__)
+
+
+    @classmethod
+    def list(self, apiclient, **kwargs):
+        cmd = listPods.listPodsCmd()
+        [setattr(cmd, key, value) for key,value in kwargs.iteritems()]
+        pod = apiclient.listPods(cmd)
+        return map(lambda e: Pod(e.__dict__), pod)
+
+
+    def update(self, apiclient, **kwargs):
+        cmd = updatePod.updatePodCmd()
+        cmd.id = self.id
+        [setattr(cmd, key, value) for key,value in kwargs.iteritems()]
+        pod = apiclient.updatePod(cmd)
+        return pod
+
+
+    def delete(self, apiclient, **kwargs):
+        cmd = deletePod.deletePodCmd()
+        cmd.id = self.id
+        [setattr(cmd, key, value) for key,value in kwargs.iteritems()]
+        pod = apiclient.deletePod(cmd)
+        return pod
+

http://git-wip-us.apache.org/repos/asf/cloudstack/blob/dd838d72/tools/marvin/marvin/base/PortForwardingRule.py
----------------------------------------------------------------------
diff --git a/tools/marvin/marvin/base/PortForwardingRule.py b/tools/marvin/marvin/base/PortForwardingRule.py
new file mode 100644
index 0000000..5b9d711
--- /dev/null
+++ b/tools/marvin/marvin/base/PortForwardingRule.py
@@ -0,0 +1,65 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements.  See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership.  The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License.  You may obtain a copy of the License at
+#
+#   http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied.  See the License for the
+# specific language governing permissions and limitations
+# under the License.
+from marvin.base import CloudStackEntity
+from marvin.cloudstackAPI import createPortForwardingRule
+from marvin.cloudstackAPI import listPortForwardingRules
+from marvin.cloudstackAPI import updatePortForwardingRule
+from marvin.cloudstackAPI import deletePortForwardingRule
+
+class PortForwardingRule(CloudStackEntity.CloudStackEntity):
+
+
+    def __init__(self, items):
+        self.__dict__.update(items)
+
+
+    @classmethod
+    def create(cls, apiclient, factory, **kwargs):
+        cmd = createPortForwardingRule.createPortForwardingRuleCmd()
+        [setattr(cmd, factoryKey, factoryValue) for factoryKey, factoryValue in factory.__dict__.iteritems()]
+        [setattr(cmd, key, value) for key,value in kwargs.iteritems()]
+        portforwardingrule = apiclient.createPortForwardingRule(cmd)
+        return PortForwardingRule(portforwardingrule.__dict__)
+
+
+    @classmethod
+    def list(self, apiclient, **kwargs):
+        cmd = listPortForwardingRules.listPortForwardingRulesCmd()
+        [setattr(cmd, key, value) for key,value in kwargs.iteritems()]
+        portforwardingrule = apiclient.listPortForwardingRules(cmd)
+        return map(lambda e: PortForwardingRule(e.__dict__), portforwardingrule)
+
+
+    def update(self, apiclient, publicport, protocol, ipaddressid, privateport, **kwargs):
+        cmd = updatePortForwardingRule.updatePortForwardingRuleCmd()
+        cmd.id = self.id
+        cmd.ipaddressid = ipaddressid
+        cmd.privateport = privateport
+        cmd.protocol = protocol
+        cmd.publicport = publicport
+        [setattr(cmd, key, value) for key,value in kwargs.iteritems()]
+        portforwardingrule = apiclient.updatePortForwardingRule(cmd)
+        return portforwardingrule
+
+
+    def delete(self, apiclient, **kwargs):
+        cmd = deletePortForwardingRule.deletePortForwardingRuleCmd()
+        cmd.id = self.id
+        [setattr(cmd, key, value) for key,value in kwargs.iteritems()]
+        portforwardingrule = apiclient.deletePortForwardingRule(cmd)
+        return portforwardingrule
+

http://git-wip-us.apache.org/repos/asf/cloudstack/blob/dd838d72/tools/marvin/marvin/base/PrivateGateway.py
----------------------------------------------------------------------
diff --git a/tools/marvin/marvin/base/PrivateGateway.py b/tools/marvin/marvin/base/PrivateGateway.py
new file mode 100644
index 0000000..907fe25
--- /dev/null
+++ b/tools/marvin/marvin/base/PrivateGateway.py
@@ -0,0 +1,52 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements.  See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership.  The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License.  You may obtain a copy of the License at
+#
+#   http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied.  See the License for the
+# specific language governing permissions and limitations
+# under the License.
+from marvin.base import CloudStackEntity
+from marvin.cloudstackAPI import createPrivateGateway
+from marvin.cloudstackAPI import listPrivateGateways
+from marvin.cloudstackAPI import deletePrivateGateway
+
+class PrivateGateway(CloudStackEntity.CloudStackEntity):
+
+
+    def __init__(self, items):
+        self.__dict__.update(items)
+
+
+    @classmethod
+    def create(cls, apiclient, factory, **kwargs):
+        cmd = createPrivateGateway.createPrivateGatewayCmd()
+        [setattr(cmd, factoryKey, factoryValue) for factoryKey, factoryValue in factory.__dict__.iteritems()]
+        [setattr(cmd, key, value) for key,value in kwargs.iteritems()]
+        privategateway = apiclient.createPrivateGateway(cmd)
+        return PrivateGateway(privategateway.__dict__)
+
+
+    @classmethod
+    def list(self, apiclient, **kwargs):
+        cmd = listPrivateGateways.listPrivateGatewaysCmd()
+        [setattr(cmd, key, value) for key,value in kwargs.iteritems()]
+        privategateway = apiclient.listPrivateGateways(cmd)
+        return map(lambda e: PrivateGateway(e.__dict__), privategateway)
+
+
+    def delete(self, apiclient, **kwargs):
+        cmd = deletePrivateGateway.deletePrivateGatewayCmd()
+        cmd.id = self.id
+        [setattr(cmd, key, value) for key,value in kwargs.iteritems()]
+        privategateway = apiclient.deletePrivateGateway(cmd)
+        return privategateway
+

http://git-wip-us.apache.org/repos/asf/cloudstack/blob/dd838d72/tools/marvin/marvin/base/Project.py
----------------------------------------------------------------------
diff --git a/tools/marvin/marvin/base/Project.py b/tools/marvin/marvin/base/Project.py
new file mode 100644
index 0000000..9c13ece
--- /dev/null
+++ b/tools/marvin/marvin/base/Project.py
@@ -0,0 +1,107 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements.  See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership.  The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License.  You may obtain a copy of the License at
+#
+#   http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied.  See the License for the
+# specific language governing permissions and limitations
+# under the License.
+from marvin.base import CloudStackEntity
+from marvin.cloudstackAPI import suspendProject
+from marvin.cloudstackAPI import createProject
+from marvin.cloudstackAPI import listProjects
+from marvin.cloudstackAPI import updateProject
+from marvin.cloudstackAPI import activateProject
+from marvin.cloudstackAPI import deleteProject
+from marvin.cloudstackAPI import deleteAccountFromProject
+from marvin.cloudstackAPI import addAccountToProject
+from marvin.cloudstackAPI import listProjectAccounts
+
+class Project(CloudStackEntity.CloudStackEntity):
+
+
+    def __init__(self, items):
+        self.__dict__.update(items)
+
+
+    def suspend(self, apiclient, **kwargs):
+        cmd = suspendProject.suspendProjectCmd()
+        cmd.id = self.id
+        [setattr(cmd, key, value) for key,value in kwargs.iteritems()]
+        project = apiclient.suspendProject(cmd)
+        return project
+
+
+    @classmethod
+    def create(cls, apiclient, factory, **kwargs):
+        cmd = createProject.createProjectCmd()
+        [setattr(cmd, factoryKey, factoryValue) for factoryKey, factoryValue in factory.__dict__.iteritems()]
+        [setattr(cmd, key, value) for key,value in kwargs.iteritems()]
+        project = apiclient.createProject(cmd)
+        return Project(project.__dict__)
+
+
+    @classmethod
+    def list(self, apiclient, **kwargs):
+        cmd = listProjects.listProjectsCmd()
+        [setattr(cmd, key, value) for key,value in kwargs.iteritems()]
+        project = apiclient.listProjects(cmd)
+        return map(lambda e: Project(e.__dict__), project)
+
+
+    def update(self, apiclient, **kwargs):
+        cmd = updateProject.updateProjectCmd()
+        cmd.id = self.id
+        [setattr(cmd, key, value) for key,value in kwargs.iteritems()]
+        project = apiclient.updateProject(cmd)
+        return project
+
+
+    def activate(self, apiclient, **kwargs):
+        cmd = activateProject.activateProjectCmd()
+        cmd.id = self.id
+        [setattr(cmd, key, value) for key,value in kwargs.iteritems()]
+        project = apiclient.activateProject(cmd)
+        return project
+
+
+    def delete(self, apiclient, **kwargs):
+        cmd = deleteProject.deleteProjectCmd()
+        cmd.id = self.id
+        [setattr(cmd, key, value) for key,value in kwargs.iteritems()]
+        project = apiclient.deleteProject(cmd)
+        return project
+
+
+    def delete_account(self, apiclient, projectid, **kwargs):
+        cmd = deleteAccountFromProject.deleteAccountFromProjectCmd()
+        cmd.id = self.id
+        cmd.projectid = projectid
+        [setattr(cmd, key, value) for key,value in kwargs.iteritems()]
+        deletefromproject = apiclient.deleteAccountFromProject(cmd)
+        return deletefromproject
+
+
+    def add_account(self, apiclient, projectid, **kwargs):
+        cmd = addAccountToProject.addAccountToProjectCmd()
+        cmd.id = self.id
+        cmd.projectid = projectid
+        [setattr(cmd, key, value) for key,value in kwargs.iteritems()]
+        accounttoproject = apiclient.addAccountToProject(cmd)
+        return accounttoproject
+
+    @classmethod
+    def list_accounts(self, apiclient, projectid, **kwargs):
+        cmd = listProjectAccounts.listProjectAccountsCmd()
+        cmd.projectid = projectid
+        [setattr(cmd, key, value) for key,value in kwargs.iteritems()]
+        projectaccounts = apiclient.listProjectAccounts(cmd)
+        return map(lambda e: Project(e.__dict__), projectaccounts)

http://git-wip-us.apache.org/repos/asf/cloudstack/blob/dd838d72/tools/marvin/marvin/base/ProjectInvitation.py
----------------------------------------------------------------------
diff --git a/tools/marvin/marvin/base/ProjectInvitation.py b/tools/marvin/marvin/base/ProjectInvitation.py
new file mode 100644
index 0000000..8576e2f
--- /dev/null
+++ b/tools/marvin/marvin/base/ProjectInvitation.py
@@ -0,0 +1,52 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements.  See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership.  The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License.  You may obtain a copy of the License at
+#
+#   http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied.  See the License for the
+# specific language governing permissions and limitations
+# under the License.
+from marvin.base import CloudStackEntity
+from marvin.cloudstackAPI import listProjectInvitations
+from marvin.cloudstackAPI import updateProjectInvitation
+from marvin.cloudstackAPI import deleteProjectInvitation
+
+class ProjectInvitation(CloudStackEntity.CloudStackEntity):
+
+
+    def __init__(self, items):
+        self.__dict__.update(items)
+
+
+    @classmethod
+    def list(self, apiclient, **kwargs):
+        cmd = listProjectInvitations.listProjectInvitationsCmd()
+        [setattr(cmd, key, value) for key,value in kwargs.iteritems()]
+        projectinvitation = apiclient.listProjectInvitations(cmd)
+        return map(lambda e: ProjectInvitation(e.__dict__), projectinvitation)
+
+
+    def update(self, apiclient, projectid, **kwargs):
+        cmd = updateProjectInvitation.updateProjectInvitationCmd()
+        cmd.id = self.id
+        cmd.projectid = projectid
+        [setattr(cmd, key, value) for key,value in kwargs.iteritems()]
+        projectinvitation = apiclient.updateProjectInvitation(cmd)
+        return projectinvitation
+
+
+    def delete(self, apiclient, **kwargs):
+        cmd = deleteProjectInvitation.deleteProjectInvitationCmd()
+        cmd.id = self.id
+        [setattr(cmd, key, value) for key,value in kwargs.iteritems()]
+        projectinvitation = apiclient.deleteProjectInvitation(cmd)
+        return projectinvitation
+

http://git-wip-us.apache.org/repos/asf/cloudstack/blob/dd838d72/tools/marvin/marvin/base/Region.py
----------------------------------------------------------------------
diff --git a/tools/marvin/marvin/base/Region.py b/tools/marvin/marvin/base/Region.py
new file mode 100644
index 0000000..3ac27bb
--- /dev/null
+++ b/tools/marvin/marvin/base/Region.py
@@ -0,0 +1,62 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements.  See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership.  The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License.  You may obtain a copy of the License at
+#
+#   http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied.  See the License for the
+# specific language governing permissions and limitations
+# under the License.
+from marvin.base import CloudStackEntity
+from marvin.cloudstackAPI import addRegion
+from marvin.cloudstackAPI import listRegions
+from marvin.cloudstackAPI import updateRegion
+from marvin.cloudstackAPI import removeRegion
+
+class Region(CloudStackEntity.CloudStackEntity):
+
+
+    def __init__(self, items):
+        self.__dict__.update(items)
+
+
+    def add(self, apiclient, endpoint, name, **kwargs):
+        cmd = addRegion.addRegionCmd()
+        cmd.id = self.id
+        cmd.endpoint = endpoint
+        cmd.name = name
+        [setattr(cmd, key, value) for key,value in kwargs.iteritems()]
+        region = apiclient.addRegion(cmd)
+        return region
+
+
+    @classmethod
+    def list(self, apiclient, **kwargs):
+        cmd = listRegions.listRegionsCmd()
+        [setattr(cmd, key, value) for key,value in kwargs.iteritems()]
+        region = apiclient.listRegions(cmd)
+        return map(lambda e: Region(e.__dict__), region)
+
+
+    def update(self, apiclient, **kwargs):
+        cmd = updateRegion.updateRegionCmd()
+        cmd.id = self.id
+        [setattr(cmd, key, value) for key,value in kwargs.iteritems()]
+        region = apiclient.updateRegion(cmd)
+        return region
+
+
+    def remove(self, apiclient, **kwargs):
+        cmd = removeRegion.removeRegionCmd()
+        cmd.id = self.id
+        [setattr(cmd, key, value) for key,value in kwargs.iteritems()]
+        region = apiclient.removeRegion(cmd)
+        return region
+

http://git-wip-us.apache.org/repos/asf/cloudstack/blob/dd838d72/tools/marvin/marvin/base/RemoteAccessVpn.py
----------------------------------------------------------------------
diff --git a/tools/marvin/marvin/base/RemoteAccessVpn.py b/tools/marvin/marvin/base/RemoteAccessVpn.py
new file mode 100644
index 0000000..fc02b5b
--- /dev/null
+++ b/tools/marvin/marvin/base/RemoteAccessVpn.py
@@ -0,0 +1,54 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements.  See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership.  The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License.  You may obtain a copy of the License at
+#
+#   http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied.  See the License for the
+# specific language governing permissions and limitations
+# under the License.
+from marvin.base import CloudStackEntity
+from marvin.cloudstackAPI import createRemoteAccessVpn
+from marvin.cloudstackAPI import listRemoteAccessVpns
+from marvin.cloudstackAPI import deleteRemoteAccessVpn
+
+class RemoteAccessVpn(CloudStackEntity.CloudStackEntity):
+
+
+    def __init__(self, items):
+        self.__dict__.update(items)
+
+
+    @classmethod
+    def create(cls, apiclient, factory, **kwargs):
+        cmd = createRemoteAccessVpn.createRemoteAccessVpnCmd()
+        [setattr(cmd, factoryKey, factoryValue) for factoryKey, factoryValue in factory.__dict__.iteritems()]
+        [setattr(cmd, key, value) for key,value in kwargs.iteritems()]
+        remoteaccessvpn = apiclient.createRemoteAccessVpn(cmd)
+        return RemoteAccessVpn(remoteaccessvpn.__dict__)
+
+
+    @classmethod
+    def list(self, apiclient, publicipid, **kwargs):
+        cmd = listRemoteAccessVpns.listRemoteAccessVpnsCmd()
+        cmd.publicipid = publicipid
+        [setattr(cmd, key, value) for key,value in kwargs.iteritems()]
+        remoteaccessvpn = apiclient.listRemoteAccessVpns(cmd)
+        return map(lambda e: RemoteAccessVpn(e.__dict__), remoteaccessvpn)
+
+
+    def delete(self, apiclient, publicipid, **kwargs):
+        cmd = deleteRemoteAccessVpn.deleteRemoteAccessVpnCmd()
+        cmd.id = self.id
+        cmd.publicipid = publicipid
+        [setattr(cmd, key, value) for key,value in kwargs.iteritems()]
+        remoteaccessvpn = apiclient.deleteRemoteAccessVpn(cmd)
+        return remoteaccessvpn
+

http://git-wip-us.apache.org/repos/asf/cloudstack/blob/dd838d72/tools/marvin/marvin/base/ResourceCount.py
----------------------------------------------------------------------
diff --git a/tools/marvin/marvin/base/ResourceCount.py b/tools/marvin/marvin/base/ResourceCount.py
new file mode 100644
index 0000000..3dc8ee8
--- /dev/null
+++ b/tools/marvin/marvin/base/ResourceCount.py
@@ -0,0 +1,34 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements.  See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership.  The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License.  You may obtain a copy of the License at
+#
+#   http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied.  See the License for the
+# specific language governing permissions and limitations
+# under the License.
+from marvin.base import CloudStackEntity
+from marvin.cloudstackAPI import updateResourceCount
+
+class ResourceCount(CloudStackEntity.CloudStackEntity):
+
+
+    def __init__(self, items):
+        self.__dict__.update(items)
+
+
+    def update(self, apiclient, domainid, **kwargs):
+        cmd = updateResourceCount.updateResourceCountCmd()
+        cmd.id = self.id
+        cmd.domainid = domainid
+        [setattr(cmd, key, value) for key,value in kwargs.iteritems()]
+        resourcecount = apiclient.updateResourceCount(cmd)
+        return resourcecount
+

http://git-wip-us.apache.org/repos/asf/cloudstack/blob/dd838d72/tools/marvin/marvin/base/ResourceLimit.py
----------------------------------------------------------------------
diff --git a/tools/marvin/marvin/base/ResourceLimit.py b/tools/marvin/marvin/base/ResourceLimit.py
new file mode 100644
index 0000000..a5d6f12
--- /dev/null
+++ b/tools/marvin/marvin/base/ResourceLimit.py
@@ -0,0 +1,43 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements.  See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership.  The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License.  You may obtain a copy of the License at
+#
+#   http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied.  See the License for the
+# specific language governing permissions and limitations
+# under the License.
+from marvin.base import CloudStackEntity
+from marvin.cloudstackAPI import listResourceLimits
+from marvin.cloudstackAPI import updateResourceLimit
+
+class ResourceLimit(CloudStackEntity.CloudStackEntity):
+
+
+    def __init__(self, items):
+        self.__dict__.update(items)
+
+
+    @classmethod
+    def list(self, apiclient, **kwargs):
+        cmd = listResourceLimits.listResourceLimitsCmd()
+        [setattr(cmd, key, value) for key,value in kwargs.iteritems()]
+        resourcelimit = apiclient.listResourceLimits(cmd)
+        return map(lambda e: ResourceLimit(e.__dict__), resourcelimit)
+
+
+    def update(self, apiclient, resourcetype, **kwargs):
+        cmd = updateResourceLimit.updateResourceLimitCmd()
+        cmd.id = self.id
+        cmd.resourcetype = resourcetype
+        [setattr(cmd, key, value) for key,value in kwargs.iteritems()]
+        resourcelimit = apiclient.updateResourceLimit(cmd)
+        return resourcelimit
+

http://git-wip-us.apache.org/repos/asf/cloudstack/blob/dd838d72/tools/marvin/marvin/base/Router.py
----------------------------------------------------------------------
diff --git a/tools/marvin/marvin/base/Router.py b/tools/marvin/marvin/base/Router.py
new file mode 100644
index 0000000..21fbe54
--- /dev/null
+++ b/tools/marvin/marvin/base/Router.py
@@ -0,0 +1,69 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements.  See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership.  The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License.  You may obtain a copy of the License at
+#
+#   http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied.  See the License for the
+# specific language governing permissions and limitations
+# under the License.
+from marvin.base import CloudStackEntity
+from marvin.cloudstackAPI import destroyRouter
+from marvin.cloudstackAPI import listRouters
+from marvin.cloudstackAPI import stopRouter
+from marvin.cloudstackAPI import rebootRouter
+from marvin.cloudstackAPI import startRouter
+
+class Router(CloudStackEntity.CloudStackEntity):
+
+
+    def __init__(self, items):
+        self.__dict__.update(items)
+
+
+    def destroy(self, apiclient, **kwargs):
+        cmd = destroyRouter.destroyRouterCmd()
+        cmd.id = self.id
+        [setattr(cmd, key, value) for key,value in kwargs.iteritems()]
+        router = apiclient.destroyRouter(cmd)
+        return router
+
+
+    @classmethod
+    def list(self, apiclient, **kwargs):
+        cmd = listRouters.listRoutersCmd()
+        [setattr(cmd, key, value) for key,value in kwargs.iteritems()]
+        router = apiclient.listRouters(cmd)
+        return map(lambda e: Router(e.__dict__), router)
+
+
+    def stop(self, apiclient, **kwargs):
+        cmd = stopRouter.stopRouterCmd()
+        cmd.id = self.id
+        [setattr(cmd, key, value) for key,value in kwargs.iteritems()]
+        router = apiclient.stopRouter(cmd)
+        return router
+
+
+    def reboot(self, apiclient, **kwargs):
+        cmd = rebootRouter.rebootRouterCmd()
+        cmd.id = self.id
+        [setattr(cmd, key, value) for key,value in kwargs.iteritems()]
+        router = apiclient.rebootRouter(cmd)
+        return router
+
+
+    def start(self, apiclient, **kwargs):
+        cmd = startRouter.startRouterCmd()
+        cmd.id = self.id
+        [setattr(cmd, key, value) for key,value in kwargs.iteritems()]
+        router = apiclient.startRouter(cmd)
+        return router
+