You are an expert in writing code in many different languages. Your goal is to perform code completion for the following code, keeping in mind the rest of the code and the file meta data.
    Metadata details:
    filename: StringMemory.m
    path of file: ./repos/MBeautifier/+MBeautifier
    
    the code of the file until where you have to start completion: classdef StringMemory < handle

    properties (SetAccess = immutable)
        Mementos;
        OriginalCodeLine;
        MemorizedCodeLine;
    end

    methods (Access = private)
        function obj = StringMemory(originalCodeLine, replacedCodeLine, mementos)
            obj.Mementos = mementos;
            obj.OriginalCodeLine = originalCodeLine;
            obj.MemorizedCodeLine = replacedCodeLine;
        end
    end

    methods (Static)
        function stringMemory = fromCodeLine(actCode)
            % Possible formats:
          
    
function stringMemory = fromCodeLine(actCode)
            % Possible formats:
            % 'text'
            % ' text '' " text2 '
            % " text "
            % " text "" ' text2"

            indices = regexp(actCode, '''|"');
            mementos = {};
            strArray = cell(1, numel(indices)+1);

            if numel(indices) > 1
                stringStartedWith = '';
                currentString = '';
                isInString = false;
                lastWasEscape = false;
                for iMatch = 1:numel(indices)
                    if ~isInString
                        if iMatch == 1
                            predecingPart = actCode(1:indices(iMatch)-1);
                        else
                            predecingPart = actCode(indices(iMatch-1)+1:indices(iMatch)-1);
                        end