def __init__(self): Resource.__init__(self) if hasattr(self, 'DEF_PROPS'): self.__defaults = copy.copy(getattr(self, 'DEF_PROPS')) else: self.__defaults = {} self.__propertySet = J2EEResourcePropertySet(self)
def __init__(self, name, parent=Cell()): Resource.__init__(self) self.name = Library.__NAMEPREFIX__ + str(name) self.parent = parent self.__classpath = [] self.__nativepath = [] self.__libraryRefs = []
def __setattr__(self, name, value): if not hasattr(self, '__propertySet'): Resource.__setattr__(self, name, value) else: if self.__defaults.has_key(name): self.setProperty(name, value) else: Resource.__setattr__(self, name, value)
def __init__(self, name, parent = Cell()): Resource.__init__(self) self.name = Library.__NAMEPREFIX__ + str(name) self.parent = parent self.__classpath = [] self.__nativepath = [] self.__libraryRefs = []
def __loadattrs__(self, skip_attrs = []): Resource.__loadattrs__(self, skip_attrs) if not self.exists(): return for serverId in AdminConfig.list('Server', self.__was_cfg_path__).splitlines(): server = None if isNodeAgentServer(serverId): server = NodeAgent(serverId, self) else: server = Node(serverId, self) self.__servers.append(server)
def remove(self): for busMemberId in AdminConfig.showAttribute(self.__getconfigid__(), 'busMembers')[1:-1].splitlines(): node = AdminConfig.showAttribute(busMemberId, 'node') server = AdminConfig.showAttribute(busMemberId, 'server') # Remove associated DataSource dsName = '_%s.%s-%s' % (node, server, self.bus) ds = DataSource(dsName) ds.remove() Resource.remove(self)
def __loadattrs__(self, skip_attrs=[]): Resource.__loadattrs__(self, skip_attrs) if not self.exists(): return for serverId in AdminConfig.list('Server', self.__was_cfg_path__).splitlines(): server = None if isNodeAgentServer(serverId): server = NodeAgent(serverId, self) else: server = Node(serverId, self) self.__servers.append(server)
def __loadattrs__(self): Resource.__loadattrs__(self) if not self.exists(): return id = AdminConfig.showAttribute(self.__getconfigid__(), 'claims') if not id is None: self.claims = CommonSecureInterop(id, self) id = AdminConfig.showAttribute(self.__getconfigid__(), 'performs') if not id is None: self.performs = CommonSecureInterop(id, self)
def __create__(self, update): if self.classPath is None: self.classPath = String(str(self.__classpath)[2:-2]).replaceAll("', '", ';') if self.nativePath is None: self.nativePath = String(str(self.__nativepath)[2:-2]).replaceAll("', '", ';') Resource.__create__(self, update) for libRef in self.__libraryRefs: libRef.__create__(update)
def __create__(self, update): if self.classPath is None: self.classPath = String(str(self.__classpath)[2:-2]).replaceAll( "', '", ';') if self.nativePath is None: self.nativePath = String(str(self.__nativepath)[2:-2]).replaceAll( "', '", ';') Resource.__create__(self, update) for libRef in self.__libraryRefs: libRef.__create__(update)
def __getattr__(self, name): if (name in Layer.DEF_CFG_ATTRS.keys()) and (self.__was_cfg_attrmap__[name] is None): obj = self.__getattrobj__(name) self.__was_cfg_attrmap__[name] = obj return obj else: return Resource.__getattr__(self, name)
def __dumpattrs__(self): str = Resource.__dumpattrs__(self) if hasattr(self, '__propertySet'): for name, prop in self.__propertySet.properties(): str = str + ("\t(%s) %s = %s\n" % (prop.type, prop.name, prop.value)) return str
def __getattr__(self, name): try: return Resource.__getattr__(self, name) except AttributeError: if hasattr(self, '__propertySet'): return self.getProperty(name) else: raise AttributeError, name
def __getattr__(self, name): try: return Resource.__getattr__(self, name) except AttributeError: if hasattr(self, '__properties'): if self.__properties.has_key(name): return self.__properties[name].value raise AttributeError, name
def __setattr__(self, name, value): if not hasattr(self, '__properties'): Resource.__setattr__(self, name, value) else: try: Resource.__getattr__(self, name) except AttributeError: self.setProperty(name, value) else: Resource.__setattr__(self, name, value)
def __init__(self, parent, initialState = 'START'): Resource.__init__(self) self.parent = parent self.initialState = initialState
def __init__(self, name, parent = Cell()): Resource.__init__(self) self.name = name self.parent = parent
def __init__(self, variableMap): Resource.__init__(self) self.variableMap = variableMap
def __init__(self, parent): Resource.__init__(self) self.__propset = {} # A hash as a container for the J2EE Properties self.parent = parent
def __init__(self, parent, initialState='START'): Resource.__init__(self) self.parent = parent self.initialState = initialState
def __init__(self, name, parent): Resource.__init__(self) self.parent = parent self.name = name #WAS attribute self.__wasid = None
def __init__(self): Resource.__init__(self) self.__properties = {}
def __create__(self, update): Resource.__create__(self, update) self.__propertySet.update()
def __loadattrs__(self): Resource.__loadattrs__(self) if not self.exists(): return classloader = AdminConfig.showAttribute(self.__getconfigid__(), 'classloader') self.__classloader = ClassLoader()
def __init__(self, parent): Resource.__init__(self) self.parent = parent
def __init__(self, deployedObjectId, parent): Resource.__init__(self) self.parent = parent self.__doi = deployedObjectId self.__classloader = None
def __create__(self, update): Resource.__create__(self, update) for name, prop in self.__properties.items(): prop.__create__(update)
def __setattr__(self, name, value): if (name == 'tunningParams'): raise AttributeError, "'tunningParams' is not writeable" else: Resource.__setattr__(self, name, value)
def __create__(self, update): Resource.__create__(self, update) self.__classloader.__create__(update)
def __init__(self, parent, index=0): Resource.__init__(self) self.parent = parent self.index = index
def __dumpattrs__(self): str = Resource.__dumpattrs__(self) if hasattr(self, '__properties'): for prop in self.__properties.values(): str = str + ("\t(unknown) %s = %s\n" % (prop.name, prop.value)) return str
def __init__(self, parent): Resource.__init__(self) self.parent = parent self.__sessionmngr = SessionManager(self)
def __setattr__(self, name, value): if name == 'type': value = was_resource_type(value) Resource.__setattr__(self, name, value)
def __getattr__(self, name): if (name == 'tunningParams'): return self.__tunning else: return Resource.__getattr__(self, name)
def __wasinit__(self): Resource.__wasinit__(self) self.tunningParams = self.__tunning.__getconfigid__()
def __init__(self, parent): Resource.__init__(self) self.parent = parent #self.__tunning__ = TunningParams(self.parent) self.__tunning = TunningParams(self)
def remove(self): for librefId in AdminConfig.list('LibraryRef').splitlines(): libName = AdminConfig.showAttribute(librefId, 'libraryName') if self.name == libName: AdminConfig.remove(librefId) Resource.remove(self)
def __init__(self, appname, parent=ApplicationServer()): Resource.__init__(self) self.appname = appname self.parent = parent self.__deployedObject = None
def __loadattrs__(self): Resource.__loadattrs__(self) if not self.exists(): return deployedObj = AdminConfig.showAttribute(self.__getconfigid__(), 'deployedObject') self.__deployedObject = DeployedObject(deployedObj, self)
def __init__(self, parent): Resource.__init__(self) self.parent = parent self.nodeName = parent.nodeName self.serverName = parent.serverName
def __create__(self, update): Resource.__create__(self, update) self.__deployedObject.__create__(update)
def __init__(self, parent=Cell()): Resource.__init__(self) self.parent = parent self.__varmap = {}
def __remove__(self, deep): self.__deployedObject.__remove__(deep) Resource.__remove__(self, deep)
def __init__(self, name, parent=Cell()): Resource.__init__(self) self.name = name self.parent = parent