~ubuntu-branches/ubuntu/trusty/python-boto/trusty

« back to all changes in this revision

Viewing changes to boto/ec2/tag.py

  • Committer: Package Import Robot
  • Author(s): Eric Evans
  • Date: 2013-07-05 17:45:01 UTC
  • mfrom: (1.1.11)
  • Revision ID: package-import@ubuntu.com-20130705174501-ez611xbm86y709t8
Tags: 2.9.6-1
New upstream release.

Show diffs side-by-side

added added

removed removed

Lines of Context:
15
15
# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
16
16
# OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABIL-
17
17
# ITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT
18
 
# SHALL THE AUTHOR BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, 
 
18
# SHALL THE AUTHOR BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
19
19
# WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
20
# OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS
21
21
# IN THE SOFTWARE.
22
22
 
 
23
 
23
24
class TagSet(dict):
24
25
    """
25
26
    A TagSet is used to collect the tags associated with a particular
27
28
    can, this dict object will be used to collect those values.  See
28
29
    :class:`boto.ec2.ec2object.TaggedEC2Object` for more details.
29
30
    """
30
 
    
 
31
 
31
32
    def __init__(self, connection=None):
32
33
        self.connection = connection
33
34
        self._current_key = None
55
56
    also the ID of the resource to which the tag is attached
56
57
    as well as the type of the resource.
57
58
    """
58
 
    
 
59
 
59
60
    def __init__(self, connection=None, res_id=None, res_type=None,
60
61
                 name=None, value=None):
61
62
        self.connection = connection
81
82
            self.value = value
82
83
        else:
83
84
            setattr(self, name, value)
84
 
 
85
 
 
86
 
            
87