classdef(Abstract, Hidden) CompactDisplayRepresentation
    % CompactDisplayRepresentation Representation of data
    % for displaying within a container or under space constraints
    %
    % This class is a structured representation of the compact display of
    % an object. This class supports 2 types of representations:
    % 1. Plain text representation, which is represented by the sub-class
    % PlainTextRepresentation
    % 2. Dimensions and class name, which is represented by the sub-class
    % DimensionsAndClassNameRepresentation
    %
    % Set the Annotation property to provide a description of your
    % object. The annotation will appear wrapped in parentheses
    % after the primary display content.
    %
    % See also matlab.display.internal.PlainTextRepresentation,
    % matlab.display.internal.DimensionsAndClassNameRepresentation
    % 
    
    % Copyright 2020 The MathWorks, Inc.

    properties(SetAccess = immutable)
        % Descriptive comment shown alongside the object description.  
        % The annotation is always wrapped in parentheses
        Annotation(1,1) string;
        % Character width associated to the CompactDisplayRepresentation
        % object
        CharacterWidth (1,1) double;
        % Resulting padded display output for representation object
        PaddedDisplayOutput (1,1) string;
    end
    
    methods
        function obj = CompactDisplayRepresentation(annotation, characterWidth, paddedDisplayOutput)
            obj.Annotation = annotation;
            obj.CharacterWidth = characterWidth;
            obj.PaddedDisplayOutput = paddedDisplayOutput;
        end
    end
end
