Merge remote-tracking branch 'telmich/master' into oo-restructure
This commit is contained in:
commit
b4fc05ba09
24 changed files with 532 additions and 611 deletions
|
|
@ -1,6 +1,7 @@
|
|||
# -*- coding: utf-8 -*-
|
||||
#
|
||||
# 2010-2011 Steven Armstrong (steven-cdist at armstrong.cc)
|
||||
# 2011 Steven Armstrong (steven-cdist at armstrong.cc)
|
||||
# 2011 Nico Schottelius (nico-cdist at schottelius.org)
|
||||
#
|
||||
# This file is part of cdist.
|
||||
#
|
||||
|
|
@ -19,12 +20,14 @@
|
|||
#
|
||||
#
|
||||
|
||||
import logging
|
||||
import os
|
||||
import collections
|
||||
|
||||
import cdist
|
||||
import cdist.core.property
|
||||
|
||||
log = logging.getLogger(__name__)
|
||||
|
||||
DOT_CDIST = '.cdist'
|
||||
|
||||
|
|
@ -65,7 +68,7 @@ class Object(object):
|
|||
for object_name in cls.list_object_names():
|
||||
type_name = object_name.split(os.sep)[0]
|
||||
object_id = os.sep.join(object_name.split(os.sep)[1:])
|
||||
yield cls(Type(type_name), object_id=object_id)
|
||||
yield cls(cdist.core.Type(type_name), object_id=object_id)
|
||||
|
||||
@classmethod
|
||||
def list_type_names(cls):
|
||||
|
|
@ -89,6 +92,10 @@ class Object(object):
|
|||
|
||||
self.__parameters = None
|
||||
self.__requirements = None
|
||||
|
||||
# Whether this object was prepared/ran
|
||||
self.prepared = False
|
||||
self.ran = False
|
||||
|
||||
def __repr__(self):
|
||||
return '<Object %s>' % self.name
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue