Interface CaptionCommandFactory
- Functional Interface:
- This is a functional interface and can therefore be used as the assignment target for a lambda expression or method reference.
Turns a space, a style and a caption into a concrete
DrawCommand.
The captioned counterpart of DrawCommandFactory: it exists as its
own type rather than as a wider version of that one so a shape's builder has no
way to supply a caption.
-
Method Summary
Modifier and TypeMethodDescriptioncreate(DrawSpace space, DrawStyle style, DrawCaption caption) Build the command this factory was created for.
-
Method Details
-
create
Build the command this factory was created for.The return type narrowed from
DrawCommandtoDrawCommand.Primitive, with the same consequence for an explicit implementor asDrawCommandFactory.create(DrawSpace, DrawStyle): lambdas are unaffected, a declaredDrawCommandreturn must narrow.
-