Ignore:
Timestamp:
10/05/11 18:45:03 (13 years ago)
Author:
sherbold
Message:
  • some changes to command parameter orders
  • removed command printRandomSesssion
  • renamed command loadSessionsFromClickstream do loadWebSequences
File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/EventBenchConsole/src/de/ugoe/cs/eventbench/commands/CMDsequenceStatistics.java

    r240 r241  
    11package de.ugoe.cs.eventbench.commands; 
    22 
     3import java.security.InvalidParameterException; 
    34import java.util.Collection; 
    45import java.util.List; 
     
    3334        @Override 
    3435        public void run(List<Object> parameters) { 
    35                 String sequencesName = "sequences"; 
    36                 if (parameters.size() == 1) { 
     36                String sequencesName; 
     37                try { 
    3738                        sequencesName = (String) parameters.get(0); 
     39                } catch (Exception e) { 
     40                        throw new InvalidParameterException(); 
    3841                } 
    3942 
     
    5255 
    5356                sequences = (Collection<List<Event<?>>>) dataObject; 
    54                 Console.traceln("Number of Sequences: " + sequences.size()); 
     57                Console.println("Number of Sequences: " + sequences.size()); 
    5558                SortedMap<Integer, Integer> lengthMap = new TreeMap<Integer, Integer>(); 
    5659                for (List<Event<?>> sequence : sequences) { 
     
    6366                } 
    6467                for (Entry<Integer, Integer> entry : lengthMap.entrySet()) { 
    65                         Console.traceln("Of length " + entry.getKey() + ": " 
     68                        Console.println("Of length " + entry.getKey() + ": " 
    6669                                        + entry.getValue()); 
    6770                } 
     
    7578        @Override 
    7679        public void help() { 
    77                 Console.println("Usage: sequenceStatistics {<sequencesName>}"); 
     80                Console.println("Usage: sequenceStatistics <sequencesName>"); 
    7881        } 
    7982 
Note: See TracChangeset for help on using the changeset viewer.