Free cookie consent management tool by TermsFeed Policy Generator

Ignore:
Timestamp:
01/08/11 13:38:14 (14 years ago)
Author:
mholper
Message:

modified Interface #1218

Location:
branches/OKBJavaConnector/HLOKBWebClient/src/main/java/at/hl/okb
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • branches/OKBJavaConnector/HLOKBWebClient/src/main/java/at/hl/okb/IECJConnector.java

    r5244 r5247  
    33import java.util.List;
    44import java.util.Map;
    5 
    6 import at.hl.wsclient.okb.AlgorithmParameter;
    75
    86/**
     
    2220   * @throws Exception
    2321   */
    24   public Map<String,AlgorithmParameter> initializeAlgorithm(String algorithmName, String algorithmClassId,
    25         String platformId, Iterable<String> algorithmParameterName) throws Exception;
     22//  public Map<String,AlgorithmParameter> initializeAlgorithm(String algorithmName, String algorithmClassId,
     23//        String platformId, Iterable<String> algorithmParameterName) throws Exception;
    2624 
    2725  /**
     
    3836   * @throws Exception
    3937   */
    40   public void initialize(String algorithm, String platform, String problem, Map<String, Object> algoParams, Map<String,Object> problemParams, Object paramFile) throws Exception;
     38  public void initialize(String algorithm, String platform, String problem) throws Exception; //, Map<String, Object> algoParams, Map<String,Object> problemParams, Object paramFile) throws Exception;
    4139
    4240  /**
     
    4543   * @throws Exception
    4644   */
    47   public void result(List<Object> resultList) throws Exception;
     45  public void result(List<Object> resultList, Map<String, Object> algoParams, Map<String, Object> problemParams,
     46      Object paramFile) throws Exception;
    4847}
  • branches/OKBJavaConnector/HLOKBWebClient/src/main/java/at/hl/okb/impl/ECJ19ConnectorImpl.java

    r5245 r5247  
    1010import at.hl.okb.wsclient.OKBClientTest;
    1111import at.hl.okb.wsclient.OKBServiceClient;
     12import at.hl.wsclient.okb.Algorithm;
    1213import at.hl.wsclient.okb.AlgorithmParameter;
    1314
     
    3334   * java.lang.String, java.util.Map, java.util.Map, java.lang.Object)
    3435   */
    35   public void initialize(String algorithm, String platform, String problem,
    36       Map<String, Object> algoParams, Map<String, Object> problemParams,
    37       Object paramFile) throws Exception {
     36  @Override
     37  public void initialize(String algorithmName, String platformName, String problemName) throws Exception {
    3838    // TODO Auto-generated method stub
    3939
    40     Long platformId = okbClient.getPlatformId(platform);
     40    Long platformId = okbClient.getPlatformId(algorithmName);
    4141    if (platformId == null)
    42       throw new Exception("Platform " + platform + " not found!");
     42      throw new Exception("Platform " + algorithmName + " not found!");
    4343
    44     Long algorithmId = okbClient.getAlgorithmId(algorithm);
     44    Long algorithmId = okbClient.getAlgorithmId(algorithmName, platformId);
    4545    if (algorithmId == null)
    46       throw new Exception("Algorithm " + algorithm + " not found!");
     46      throw new Exception("Algorithm " + algorithmName + " for Platform" + platformName + " not found!");
    4747
    48     Long problemId = okbClient.getProblemId(problem);
     48    Long problemId = okbClient.getProblemId(problemName);
    4949    if (problemId == null)
    50       throw new Exception("Proble " + problem + " not found!");
     50      throw new Exception("Proble " + problemName + " not found!");
    5151
    52     okbClient.checkAlgoParamsExists(algorithmId, algoParams);
     52    //okbClient.checkAlgoParamsExists(algorithmId, algoParams);
    5353    // check problemParams(problemParams)
    5454
     
    6464   * @see at.hl.okb.IECJConnector#result(java.util.List)
    6565   */
    66   public void result(List<Object> resultList) throws Exception {
     66  @Override
     67  public void result(List<Object> resultList, Map<String, Object> algoParams, Map<String, Object> problemParams,
     68      Object paramFile) throws Exception {
    6769    // TODO Auto-generated method stub
    68 
     70   
     71    //create Experiment if algoparams empty and problemparams empty (in HL)
     72    //create missing Params in Algo and Problem (if not exits for experiment)
     73    //create Datatype if missing
     74   
    6975  }
    7076
    71   @Override
    72   public Map<String, AlgorithmParameter> initializeAlgorithm(
    73       String algorithmName, String algorithmClassName, String platformName,
    74       Iterable<String> algorithmParameterName) throws Exception {
    75    
    76     /*Long platformId = okbClient.getPlatformId(platformName);
    77     if (platformId==null)
    78       throw new Exception("Platform " + platformName + " not found!");   
    79    
    80     okbClient.getAlgorithm(algorithmName, Long.valueOf(algorithmClassId), platformId)
    81    
    82     if (okbClient.getAlgorithmClassId(algorithmName)==null)
    83       throw new Exception("Algorithm " + algorithmName + " not found in HL!");
    84    
    85    
    86       */
    87     return null;
    88    
    89   }
     77//  @Override
     78//  public Map<String, AlgorithmParameter> initializeAlgorithm(
     79//      String algorithmName, String algorithmClassName, String platformName,
     80//      Iterable<String> algorithmParameterName) throws Exception {
     81//   
     82//    Long platformId = okbClient.getPlatformId(platformName);
     83//    if (platformId==null)
     84//      throw new Exception("Platform " + platformName + " not found in HL!");   
     85//
     86////    Long algorithmClassId = okbClient.getAlgorithmClassId(algorithmClassName);
     87////    if (algorithmClassId==null)
     88////      throw new Exception("AlgorithmClass " + platformName + " not found in HL!");   
     89//   
     90//    Long algorithmId = okbClient.getAlgorithmId(algorithmName, /*algorithmClassId*/ platformId);
     91//    if (algorithmId==null)
     92//      throw new Exception("Algorithm " + algorithmName + " not found in HL!");
     93//
     94//   
     95//
     96//    return null;
     97//   
     98//  }
    9099}
Note: See TracChangeset for help on using the changeset viewer.