+/*
+ * Copyright (c) 2014 Cisco Systems, Inc. and others. All rights reserved.
+ *
+ * This program and the accompanying materials are made available under the
+ * terms of the Eclipse Public License v1.0 which accompanies this distribution,
+ * and is available at http://www.eclipse.org/legal/epl-v10.html
+ */
package org.opendaylight.controller.md.sal.common.impl.service;
import java.util.Map;
import org.opendaylight.controller.md.sal.common.api.data.DataChange;
import org.opendaylight.controller.md.sal.common.api.data.DataChangeEvent;
+import org.opendaylight.yangtools.concepts.Immutable;
+import org.opendaylight.yangtools.concepts.Path;
-public class DataChangeEventImpl<P, D> implements DataChangeEvent<P, D> {
+public class DataChangeEventImpl<P extends Path<P>, D> implements DataChangeEvent<P, D>, Immutable {
private final DataChange<P, D> dataChange;
private final D updatedOperationalSubtree;
private final D updatedConfigurationSubtree;
-
-
-
+
+
+
public DataChangeEventImpl(DataChange<P, D> dataChange, D originalConfigurationSubtree,
D originalOperationalSubtree, D updatedOperationalSubtree, D updatedConfigurationSubtree) {
super();
this.updatedConfigurationSubtree = updatedConfigurationSubtree;
}
+ @Override
+ public D getOriginalConfigurationSubtree() {
+ return originalConfigurationSubtree;
+ }
+
+ @Override
+ public D getOriginalOperationalSubtree() {
+ return originalOperationalSubtree;
+ }
+
@Override
public D getUpdatedOperationalSubtree() {
return updatedOperationalSubtree;