src/auto/Replayer.java
private JoyData[] readAllData()
    {
        m_fileReader = new FileReader(m_sFileName);
        m_iMax = m_fileReader.readInt();
        JoyData joyData[] = new JoyData[m_iMax];
        
        for(int index = 0; index < m_iMax; index++)
        {
            joyData[index] = new JoyData();
            joyData[index].setTime(m_fileReader.readDouble());
            joyData[index].setX(m_fileReader.readDouble());
            joyData[index].setY(m_fileReader.readDouble());
            joyData[index].setPush(m_fileReader.readBoolean());
        }
        
        m_fileReader.close();
        return joyData;
    }
/**
     * Reads all the data from the file at once and stores them into an array
     * that we can access.
     */
Reads all the data from the file at once and stores them into an array
that we can access.
Reads all the data from the file at once and stores them into an array that we can access .
private JoyData[] readAllData()
    {
        m_fileReader = new FileReader(m_sFileName);
        m_iMax = m_fileReader.readInt();
        JoyData joyData[] = new JoyData[m_iMax];
        for(int index = 0; index < m_iMax; index++)
        {
            joyData[index] = new JoyData();
            joyData[index].setTime(m_fileReader.readDouble());
            joyData[index].setX(m_fileReader.readDouble());
            joyData[index].setY(m_fileReader.readDouble());
            joyData[index].setPush(m_fileReader.readBoolean());
        }
        m_fileReader.close();
        return joyData;
    }
private JoyData [ ] readAllData ( ) { m_fileReader = new FileReader ( m_sFileName ) ; m_iMax = m_fileReader . readInt ( ) ; JoyData joyData [ ] = new JoyData [ m_iMax ] ; for ( int index = 0 ; index < m_iMax ; index ++ ) { joyData [ index ] = new JoyData ( ) ; joyData [ index ] . setTime ( m_fileReader . readDouble ( ) ) ; joyData [ index ] . setX ( m_fileReader . readDouble ( ) ) ; joyData [ index ] . setY ( m_fileReader . readDouble ( ) ) ; joyData [ index ] . setPush ( m_fileReader . readBoolean ( ) ) ; } m_fileReader . close ( ) ; return joyData ; }
Reads all the data from the file at once and stores them into an array
 that we can access.
Reads all the data from the file at once and stores them into an array that we can access .