def __init__(self, resource): self.is_file = False if isinstance(resource, str): from resource import ContentObject co = ContentObject.from_file(resource) self.gff = Gff(co) self.is_file = True else: self.container = resource[1] self.gff = Gff(resource[0])
def __init__(self, resource, instance=False): self._scripts = None self._vars = None self.is_instance = instance if not instance: if isinstance(resource, str): from resource import ContentObject co = ContentObject.from_file(resource) self.gff = Gff(co) else: self.container = resource[1] self.gff = Gff(resource[0]) else: self.gff = resource
def __init__(self, resource): self.is_file = False self.reply_cache = None self.entry_cache = None if isinstance(resource, str): from resource import ContentObject co = ContentObject.from_file(resource) self.gff = Gff(co) self.is_file = True else: self.container = resource[1] co = resource[0] self.gff = Gff(co) self._resref = co.resref