From dc632f300741074836619784f093e13a33187702 Mon Sep 17 00:00:00 2001 From: Michael Zillgith Date: Tue, 23 Jan 2018 11:29:41 +0100 Subject: [PATCH] - added ObjectReference.getLdName method --- .../java/org/openmuc/openiec61850/ObjectReference.java | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/src/main/java/org/openmuc/openiec61850/ObjectReference.java b/src/main/java/org/openmuc/openiec61850/ObjectReference.java index fa8fb2d..ff03835 100644 --- a/src/main/java/org/openmuc/openiec61850/ObjectReference.java +++ b/src/main/java/org/openmuc/openiec61850/ObjectReference.java @@ -49,6 +49,14 @@ public final class ObjectReference implements Iterable { } return nodeNames.get(nodeNames.size() - 1); } + + public String getLdName() { + if (nodeNames == null) { + parseForNameList(); + } + + return nodeNames.get(0); + } @Override public String toString() {