Class MSTInstanceImporter

java.lang.Object
es.urjc.etsii.grafo.io.InstanceImporter<MSTInstance>
es.urjc.etsii.grafo.MST.model.MSTInstanceImporter

public class MSTInstanceImporter extends InstanceImporter<MSTInstance>
  • Constructor Details

    • MSTInstanceImporter

      public MSTInstanceImporter()
  • Method Details

    • importInstance

      public MSTInstance importInstance(BufferedReader reader, String suggestedName) throws IOException
      Load instance from file. This method is called by the framework when a new instance is being loaded. Note that instance load time is never considered in the total execution time.
      Specified by:
      importInstance in class InstanceImporter<MSTInstance>
      Parameters:
      reader - Input buffer, managed by the framework.
      suggestedName - Suggested filename for the instance, can be ignored. By default, the suggested filename is built by removing the path and extension info. For example, for the path "instances/TSP/TSP-1.txt", the suggestedName would be "TSP-1"
      Returns:
      immutable instance
      Throws:
      IOException - If an error is encountered while the instance is being parsed