Gets the uberParent attribute of the Equipment object @return The uberParent value
()
| 1949 | * @return The uberParent value |
| 1950 | */ |
| 1951 | public Equipment getUberParent() |
| 1952 | { |
| 1953 | if (getParent() == null) |
| 1954 | { |
| 1955 | return this; |
| 1956 | } |
| 1957 | |
| 1958 | Equipment anEquip = getParent(); |
| 1959 | |
| 1960 | while (anEquip.getParent() != null) |
| 1961 | { |
| 1962 | anEquip = anEquip.getParent(); |
| 1963 | } |
| 1964 | |
| 1965 | return anEquip; |
| 1966 | } |
| 1967 | |
| 1968 | /** |
| 1969 | * Get used charges |