/[svn]/jlscp/trunk/src/org/linuxsampler/lscp/DbDirectoryInfo.java
ViewVC logotype

Diff of /jlscp/trunk/src/org/linuxsampler/lscp/DbDirectoryInfo.java

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1345 by iliev, Thu May 24 20:17:25 2007 UTC revision 1346 by iliev, Thu Sep 13 22:02:03 2007 UTC
# Line 27  import java.text.ParseException; Line 27  import java.text.ParseException;
27  import java.text.SimpleDateFormat;  import java.text.SimpleDateFormat;
28  import java.util.Date;  import java.util.Date;
29    
30    import static org.linuxsampler.lscp.Parser.*;
31    
32    
33  /**  /**
34   * Provides information about a database instrument directory.   * Provides information about a database instrument directory.
# Line 96  public class DbDirectoryInfo { Line 98  public class DbDirectoryInfo {
98                  if(getParentDirectoryPath() == null) return null;                  if(getParentDirectoryPath() == null) return null;
99                  if(getParentDirectoryPath().length() == 1) {                  if(getParentDirectoryPath().length() == 1) {
100                          if(!getParentDirectoryPath().equals("/")) return null;                          if(!getParentDirectoryPath().equals("/")) return null;
101                          return getParentDirectoryPath() + getName();                          return getParentDirectoryPath() + toEscapedFileName(getName());
102                  }                  }
103                                    
104                  return getParentDirectoryPath() + "/" + getName();                  return getParentDirectoryPath() + "/" + toEscapedFileName(getName());
105          }          }
106                    
107          /**          /**
# Line 124  public class DbDirectoryInfo { Line 126  public class DbDirectoryInfo {
126          parse(String s) throws LscpException {          parse(String s) throws LscpException {
127                  if(s.startsWith("DESCRIPTION: ")) {                  if(s.startsWith("DESCRIPTION: ")) {
128                          description = s.substring("DESCRIPTION: ".length());                          description = s.substring("DESCRIPTION: ".length());
129                            description = toNonEscapedText(description);
130                  } else if(s.startsWith("CREATED: ")) {                  } else if(s.startsWith("CREATED: ")) {
131                          s = s.substring("CREATED: ".length());                          s = s.substring("CREATED: ".length());
132                          try { dateCreated.setTime(dateFormat.parse(s).getTime()); }                          try { dateCreated.setTime(dateFormat.parse(s).getTime()); }

Legend:
Removed from v.1345  
changed lines
  Added in v.1346

  ViewVC Help
Powered by ViewVC