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

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

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

revision 1201 by iliev, Mon Apr 2 20:43:58 2007 UTC revision 1202 by iliev, Thu May 24 20:17:25 2007 UTC
# Line 30  public final class ServerInfo implements Line 30  public final class ServerInfo implements
30          private String desc = null;          private String desc = null;
31          private String ver = null;          private String ver = null;
32          private String protoVer = null;          private String protoVer = null;
33            private boolean instrumentsDbSupport = false;
34                    
35          /**          /**
36           * Creates a new instance of <code>ServerInfo</code> and parses the information           * Creates a new instance of <code>ServerInfo</code> and parses the information
# Line 64  public final class ServerInfo implements Line 65  public final class ServerInfo implements
65          getProtocolVersion() { return protoVer; }          getProtocolVersion() { return protoVer; }
66                    
67          /**          /**
68             * Determines whether the backend is
69             * build with instruments database support.
70             */
71            public boolean
72            hasInstrumentsDbSupport() { return instrumentsDbSupport; }
73            
74            /**
75           * Parses a line of text.           * Parses a line of text.
76           * @param s The string to be parsed.           * @param s The string to be parsed.
77           * @return <code>true</code> if the line has been processed, <code>false</code> otherwise.           * @return <code>true</code> if the line has been processed, <code>false</code> otherwise.
# Line 76  public final class ServerInfo implements Line 84  public final class ServerInfo implements
84                          ver = s.substring("VERSION: ".length());                          ver = s.substring("VERSION: ".length());
85                  } else if(s.startsWith("PROTOCOL_VERSION: ")) {                  } else if(s.startsWith("PROTOCOL_VERSION: ")) {
86                          protoVer = s.substring("PROTOCOL_VERSION: ".length());                          protoVer = s.substring("PROTOCOL_VERSION: ".length());
87                    } else if(s.startsWith("INSTRUMENTS_DB_SUPPORT: ")) {
88                            s = s.substring("INSTRUMENTS_DB_SUPPORT: ".length());
89                            if(s.equalsIgnoreCase("yes")) instrumentsDbSupport = true;
90                  } else return false;                  } else return false;
91                                    
92                  return true;                  return true;

Legend:
Removed from v.1201  
changed lines
  Added in v.1202

  ViewVC Help
Powered by ViewVC