Class ConnectStringParser

java.lang.Object
org.olap4j.impl.ConnectStringParser

public class ConnectStringParser extends Object
Parser for olap4j connect strings.
Since:
Dec 12, 2007
Version:
$Id$
Author:
jhyde
  • Method Details

    • parseConnectString

      public static Map<String,String> parseConnectString(String s)
      Converts an OLE DB connect string into a Map.

      For example, "Provider=MSOLAP; DataSource=LOCALHOST;" becomes the set of (key, value) pairs {("Provider","MSOLAP"), ("DataSource", "LOCALHOST")}. Another example is Provider='sqloledb';Data Source='MySqlServer';Initial Catalog='Pubs';Integrated Security='SSPI';.

      This method implements as much as possible of the OLE DB connect string syntax specification.

      The return value is a map which:

      • preserves the order in that the entries occurred;
      • is not case-sensitive when looking up properties
      Parameters:
      s - Connect string
      Returns:
      Map containing (name, value) pairs, stored in the order that they occurred in the connect string