commit | c9546a3646423a92254708fb00a155669a8a1b2a | [log] [tgz] |
---|---|---|
author | Sho SHIMIZU <sshimizu@us.fujitsu.com> | Tue Nov 10 11:22:28 2015 -0800 |
committer | Gerrit Code Review <gerrit@onlab.us> | Thu Nov 19 22:34:20 2015 +0000 |
tree | 8c70263b95ffee55fa9361e9f99d10d1d5ed73aa | |
parent | 0be872498322e0e6c4aa2344b387ca053492ba33 [diff] [blame] |
Refactor ResourcePath internal implementation Change-Id: Idb3aa467b4d0e8181adf0d1766812a038b5408ac
diff --git a/core/net/src/main/java/org/onosproject/net/intent/impl/compiler/MplsPathIntentCompiler.java b/core/net/src/main/java/org/onosproject/net/intent/impl/compiler/MplsPathIntentCompiler.java index acc5a5d..b75ca5d 100644 --- a/core/net/src/main/java/org/onosproject/net/intent/impl/compiler/MplsPathIntentCompiler.java +++ b/core/net/src/main/java/org/onosproject/net/intent/impl/compiler/MplsPathIntentCompiler.java
@@ -146,8 +146,8 @@ private Optional<MplsLabel> findMplsLabel(LinkKey link) { return resourceService.getAvailableResources(new ResourcePath(link)).stream() - .filter(x -> x.lastComponent() instanceof MplsLabel) - .map(x -> (MplsLabel) x.lastComponent()) + .filter(x -> x.last() instanceof MplsLabel) + .map(x -> (MplsLabel) x.last()) .findFirst(); }