code: def cast_out(self, klass):
          
          if _debug: SequenceOfAny._debug("cast_out %r", klass)
  
          # make sure it is a list
          if not issubclass(klass, List):
              raise DecodingError("%r is not a list" % (klass,))
  
          # build a helper
          helper = klass()
  
          # make a copy of the tag list
          t = TagList(self.tagList[:])
  
          # let it decode itself
          helper.decode(t)
  
          # make sure everything was consumed
          if len(t) != 0:
              raise DecodingError("incomplete cast")
  
          return helper.value
docs: Interpret the content as a particular class.