def visitEncapsulatedShape(self, ctx: ShExDocParser.EncapsulatedShapeContext):
enc_shape = ShexOneOfShapeParser(self.context)<EOL>enc_shape.visit(ctx.innerShape())<EOL>self.expression = enc_shape.expression<EOL>self._card_annotations_and_semacts(ctx)<EOL>
encapsulatedShape: '(' innerShape ')' cardinality? annotation* semanticActions