@Test public void testPath() { Path a = new Path("", true); Assert.assertEquals("", a.getDevice()); Assert.assertEquals("", a.getMeasurement()); Path b = new Path("root.\"sg\".\"d1\".\"s1\"", true); Assert.assertEquals("root.\"sg\".\"d1\"", b.getDevice()); Assert.assertEquals("\"s1\"", b.getMeasurement()); Path c = new Path("root.\"sg\".\"d1\".s1", true); Assert.assertEquals("root.\"sg\".\"d1\"", c.getDevice()); Assert.assertEquals("s1", c.getMeasurement()); Path d = new Path("s1", true); Assert.assertEquals("s1", d.getMeasurement()); Assert.assertEquals("", d.getDevice()); Path e = new Path("root.\"s.g\".d1.\"s..\\\"s1\"", true); Assert.assertEquals("root.\"s.g\".d1", e.getDevice()); Assert.assertEquals("\"s..\\\"s1\"", e.getMeasurement()); }
public Path() {}
Path implements Serializable, Comparable<Path> { public Path() {} }
Path implements Serializable, Comparable<Path> { public Path() {} Path(); @SuppressWarnings("the path that wouldn't be split")  Path(String pathSc);  Path(String pathSc, boolean needSplit);  Path(String device, String measurement); }
Path implements Serializable, Comparable<Path> { public Path() {} Path(); @SuppressWarnings("the path that wouldn't be split")  Path(String pathSc);  Path(String pathSc, boolean needSplit);  Path(String device, String measurement); String getFullPath(); String getDevice(); String getMeasurement(); String getFullPathWithAlias(); @Override int hashCode(); @Override boolean equals(Object obj); boolean equals(String obj); @Override int compareTo(Path path); @Override String toString(); @Override Path clone(); }
Path implements Serializable, Comparable<Path> { public Path() {} Path(); @SuppressWarnings("the path that wouldn't be split")  Path(String pathSc);  Path(String pathSc, boolean needSplit);  Path(String device, String measurement); String getFullPath(); String getDevice(); String getMeasurement(); String getFullPathWithAlias(); @Override int hashCode(); @Override boolean equals(Object obj); boolean equals(String obj); @Override int compareTo(Path path); @Override String toString(); @Override Path clone();  }