Seal YangExpr hierarchy
[yangtools.git] / xpath / yang-xpath-api / src / main / java / org / opendaylight / yangtools / yang / xpath / api / YangNumberExpr.java
1 /*
2  * Copyright (c) 2018 Pantheon Technologies, s.r.o.  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.yangtools.yang.xpath.api;
9
10 import com.google.common.annotations.Beta;
11 import org.eclipse.jdt.annotation.Nullable;
12
13 /**
14  * A number-bearing expression.
15  */
16 @Beta
17 public abstract sealed class YangNumberExpr implements YangExpr permits BigDecimalNumberExpr, DoubleNumberExpr {
18     private static final long serialVersionUID = 1L;
19
20     public abstract Number getNumber();
21
22     public abstract YangXPathMathSupport getSupport();
23
24     @Override
25     public abstract int hashCode();
26
27     @Override
28     public abstract boolean equals(@Nullable Object obj);
29 }