private String performPadOperation ( String source , Integer length , Character padChar , String direction ) { if ( direction . equals ( "Start" ) ) { return Strings . padStart ( source , length , padChar ) ; } else { return Strings . padEnd ( source , length , padChar ) ; } }
Perform the pad operation itself and returns the result