2 * Copyright (c) 2017 Pantheon Technologies s.r.o. and others. All rights reserved.
4 * This program and the accompanying materials are made available under the
5 * terms of the Eclipse Public License v1.0 which accompanies this distribution,
6 * and is available at http://www.eclipse.org/legal/epl-v10.html
9 package org.opendaylight.openflowplugin.impl.services.singlelayer;
11 import java.util.List;
12 import org.opendaylight.openflowplugin.api.openflow.device.DeviceContext;
13 import org.opendaylight.openflowplugin.api.openflow.device.RequestContext;
14 import org.opendaylight.openflowplugin.api.openflow.statistics.ofpspecific.EventIdentifier;
15 import org.opendaylight.openflowplugin.impl.services.AbstractMultipartRequestCallback;
16 import org.opendaylight.yang.gen.v1.urn.opendaylight.multipart.types.rev170112.MultipartReply;
17 import org.opendaylight.yang.gen.v1.urn.opendaylight.openflow.protocol.rev130731.OfHeader;
19 public class SingleLayerMultipartRequestCallback<T extends OfHeader> extends AbstractMultipartRequestCallback<T> {
21 public SingleLayerMultipartRequestCallback(RequestContext<List<T>> context,
23 DeviceContext deviceContext,
24 EventIdentifier eventIdentifier) {
25 super(context, requestType, deviceContext, eventIdentifier);
29 protected boolean isMultipart(OfHeader result) {
30 return result instanceof MultipartReply;
34 protected boolean isReqMore(T result) {
35 return ((MultipartReply) result).isRequestMore();