Class Swap

  • All Implemented Interfaces:
    RawObj

    public class Swap
    extends Object
    implements RawObj
    Worker Swap Data Structure
    • Constructor Detail

      • Swap

        public Swap​(List<Integer> x1,
                    List<Integer> x2,
                    List<Integer> y1,
                    List<Integer> y2)
        Swap Constructor
        Parameters:
        x1 - First Element start position to move
        x2 - First Element end position to move
        y1 - Second Element start position to move
        y2 - Second Element end position to move
    • Method Detail

      • getRawData

        public ArrayList<String> getRawData()
        Description copied from interface: RawObj
        Convert data to a list of string that contains a user readable information about the class
        Specified by:
        getRawData in interface RawObj
        Returns:
        data converted into an array of string user readable information about the class
      • getX1

        public List<Integer> getX1()
        Get First Element start position to move
        Returns:
        First Element start position to move
      • getX2

        public List<Integer> getX2()
        Get First Element end position to move
        Returns:
        First Element end position to move
      • getY1

        public List<Integer> getY1()
        Get Second Element start position to move
        Returns:
        Second Element start position to move
      • getY2

        public List<Integer> getY2()
        Get Second Element end position to move
        Returns:
        Second Element end position to move