springpython.container
index
/home/gturnquist/spring-python-1.1.x/src/springpython/container/__init__.py

Copyright 2006-2008 SpringSource (http://springsource.com), All Rights Reserved
 
Licensed 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.

 
Package Contents
       

 
Classes
       
__builtin__.object
ObjectContainer
exceptions.Exception(exceptions.BaseException)
AbstractObjectException
InvalidObjectScope

 
class AbstractObjectException(exceptions.Exception)
    Raised when the user's code tries to get an abstract object from
the container.
 
 
Method resolution order:
AbstractObjectException
exceptions.Exception
exceptions.BaseException
__builtin__.object

Data descriptors defined here:
__weakref__
list of weak references to the object (if defined)

Methods inherited from exceptions.Exception:
__init__(...)
x.__init__(...) initializes x; see x.__class__.__doc__ for signature

Data and other attributes inherited from exceptions.Exception:
__new__ = <built-in method __new__ of type object>
T.__new__(S, ...) -> a new object with type S, a subtype of T

Methods inherited from exceptions.BaseException:
__delattr__(...)
x.__delattr__('name') <==> del x.name
__getattribute__(...)
x.__getattribute__('name') <==> x.name
__getitem__(...)
x.__getitem__(y) <==> x[y]
__getslice__(...)
x.__getslice__(i, j) <==> x[i:j]
 
Use of negative indices is not supported.
__reduce__(...)
__repr__(...)
x.__repr__() <==> repr(x)
__setattr__(...)
x.__setattr__('name', value) <==> x.name = value
__setstate__(...)
__str__(...)
x.__str__() <==> str(x)
__unicode__(...)

Data descriptors inherited from exceptions.BaseException:
__dict__
args
message

 
class InvalidObjectScope(exceptions.Exception)
    
Method resolution order:
InvalidObjectScope
exceptions.Exception
exceptions.BaseException
__builtin__.object

Data descriptors defined here:
__weakref__
list of weak references to the object (if defined)

Methods inherited from exceptions.Exception:
__init__(...)
x.__init__(...) initializes x; see x.__class__.__doc__ for signature

Data and other attributes inherited from exceptions.Exception:
__new__ = <built-in method __new__ of type object>
T.__new__(S, ...) -> a new object with type S, a subtype of T

Methods inherited from exceptions.BaseException:
__delattr__(...)
x.__delattr__('name') <==> del x.name
__getattribute__(...)
x.__getattribute__('name') <==> x.name
__getitem__(...)
x.__getitem__(y) <==> x[y]
__getslice__(...)
x.__getslice__(i, j) <==> x[i:j]
 
Use of negative indices is not supported.
__reduce__(...)
__repr__(...)
x.__repr__() <==> repr(x)
__setattr__(...)
x.__setattr__('name', value) <==> x.name = value
__setstate__(...)
__str__(...)
x.__str__() <==> str(x)
__unicode__(...)

Data descriptors inherited from exceptions.BaseException:
__dict__
args
message

 
class ObjectContainer(__builtin__.object)
    ObjectContainer is a container which uses multiple Config objects to read sources of
object definitions. When a object is requested from this container, it may optionally
pull the object from a scoped cache. If there is no stored copy of the object, it
uses the scanned definition and its associated ObjectFactory to create an instance. It
can then optionally store it in a scoped cache for future usage (e.g. singleton).
 
Object definitions are stored in the container in a neutral format, decoupling the
container entirely from the original source location. This means that XML, python code,
and other formats may all contain definitions. By the time they
reach this container, it doesn't matter what their original format was when a object
instance is needed. NOTE: This explicitly means that one object in one source
can refer to another object in another source OF ANY FORMAT as a property.
 
  Methods defined here:
__init__(self, config=None)
get_object(self, name, ignore_abstract=False)
This function attempts to find the object in the singleton cache. If not found, 
delegates to _create_object in order to hunt for the definition, and request a
object factory to generate one.

Data descriptors defined here:
__dict__
dictionary for instance variables (if defined)
__weakref__
list of weak references to the object (if defined)