package com.huawei.globe;
public class Split
{
public static void main(String[] args)
{
Split s = new Split();
String a = "4097";
String b = "DropInsert";
String c = "STM16-8.J1.K2.L3.M4";
String d = "53";
String e = s.initPort(a, b, c, d);
System.out.println(e);
}
public String initPort(String trail_level, String cross_type, String cells,
String time_slot)
{
String[] s;
if (cells == null)
{
return cells;
}
else
{
s = cells.split("//.");
if ("LINK".equals(cross_type) || "Logical".equals(cross_type)
|| "Physical".equals(cross_type))
{
return cells;
}
else
{
if ("0".equals(time_slot))
{
return cells;
}
else
{
int ts = Integer.parseInt(time_slot);
System.out.println(ts);
return s[0];
}
}
}
}
}