2 * Copyright (c) 2024 PANTHEON.tech, 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
8 package org.opendaylight.restconf.server.api;
10 import static java.util.Objects.requireNonNull;
12 import com.google.common.annotations.Beta;
15 * The content of {@code error-info} {@code anydata}.
17 // FIXME: String here is legacy coming from RestconfError. This really should be a FormattableBody or similar, i.e.
18 // structured content which itself is formattable -- unlike FormattableBody, though, it needs to be defined as
19 // being formatted to a output. This format should include writing.
20 // FIXME: given that the normalized-node-based FormattableBody lives in server.spi, this should probably be an interface
21 // implemented in at server.spi level.
23 public record ServerErrorInfo(String value) {
24 public ServerErrorInfo {
25 requireNonNull(value);