Add update method of handlers for REST services
[netconf.git] / restconf / restconf-nb-rfc8040 / src / main / java / org / opendaylight / restconf / nb / rfc8040 / services / simple / api / UpdateHandlers.java
1 /*
2  * Copyright (c) 2017 Pantheon technologies s.r.o. and others.  All rights reserved.
3  *
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
7  */
8 package org.opendaylight.restconf.nb.rfc8040.services.simple.api;
9
10 /**
11  * Allow update of handlers in web application services, if needed.
12  */
13 public interface UpdateHandlers {
14
15     /**
16      * Update method for handlers in specific service (resource) of web application.
17      * Has to be implemented as synchronized to avoid conflict of update variables in multithreaded application.
18      *
19      * @param handlers
20      *            array of handlers
21      */
22     default void updateHandlers(final Object... handlers) {
23         throw new UnsupportedOperationException("This method it's not allowed for this service by default.");
24     }
25 }