ttomcat-1778514358873.zip-extract/_dependencies/maven/com.h2database_h2-2.2.220/org/h2/value/ValueNull.java

Path
ttomcat-1778514358873.zip-extract/_dependencies/maven/com.h2database_h2-2.2.220/org/h2/value/ValueNull.java
Status
scanned
Type
file
Name
ValueNull.java
Extension
.java
Programming language
Java
Mime type
text/x-java
File type
Java source, ASCII text
Tag

      
    
Rootfs path

      
    
Size
2927 (2.9 KB)
MD5
c881e4422eae08bc5b424597e54d46b3
SHA1
7e5d9f4b784a330890c1f94e07d5d3c2912e6680
SHA256
6ff98f1795ad7b1fe02665c2614b479666bba044f48a58e562ab34504ca27b5e
SHA512

      
    
SHA1_git
49ca3e14b8482dbc6bd1644e6828fb827d208acf
Is binary

      
    
Is text
True
Is archive

      
    
Is media

      
    
Is legal

      
    
Is manifest

      
    
Is readme

      
    
Is top level

      
    
Is key file

      
    
ValueNull.java | 2.9 KB |

/* * Copyright 2004-2023 H2 Group. Multiple-Licensed under the MPL 2.0, * and the EPL 1.0 (https://h2database.com/html/license.html). * Initial Developer: H2 Group */ package org.h2.value; import java.io.InputStream; import java.io.Reader; import java.math.BigDecimal; import org.h2.engine.CastDataProvider; import org.h2.message.DbException; /** * Implementation of NULL. NULL is not a regular data type. */ public final class ValueNull extends Value { /** * The main NULL instance. */ public static final ValueNull INSTANCE = new ValueNull(); /** * The precision of NULL. */ static final int PRECISION = 1; /** * The display size of the textual representation of NULL. */ static final int DISPLAY_SIZE = 4; private ValueNull() { // don't allow construction } @Override public StringBuilder getSQL(StringBuilder builder, int sqlFlags) { return builder.append("NULL"); } @Override public TypeInfo getType() { return TypeInfo.TYPE_NULL; } @Override public int getValueType() { return NULL; } @Override public int getMemory() { // Singleton value return 0; } @Override public String getString() { return null; } @Override public Reader getReader() { return null; } @Override public Reader getReader(long oneBasedOffset, long length) { return null; } @Override public byte[] getBytes() { return null; } @Override public InputStream getInputStream() { return null; } @Override public InputStream getInputStream(long oneBasedOffset, long length) { return null; } @Override public boolean getBoolean() { throw DbException.getInternalError(); } @Override public byte getByte() { throw DbException.getInternalError(); } @Override public short getShort() { throw DbException.getInternalError(); } @Override public int getInt() { throw DbException.getInternalError(); } @Override public long getLong() { throw DbException.getInternalError(); } @Override public BigDecimal getBigDecimal() { return null; } @Override public float getFloat() { throw DbException.getInternalError(); } @Override public double getDouble() { throw DbException.getInternalError(); } @Override public int compareTypeSafe(Value v, CompareMode mode, CastDataProvider provider) { throw DbException.getInternalError("compare null"); } @Override public boolean containsNull() { return true; } @Override public int hashCode() { return 0; } @Override public boolean equals(Object other) { return other == this; } }
Detected license expression
mpl-2.0 AND epl-1.0
Detected license expression (SPDX)
MPL-2.0 AND EPL-1.0
Percentage of license text
3.31
Copyrights
- end_line: 2
  copyright: Copyright 2004-2023 H2 Group. Multiple-Licensed
  start_line: 2
Holders
- holder: H2 Group. Multiple-Licensed
  end_line: 2
  start_line: 2
Authors

      
    
License detections License expression License expression SPDX
mpl_2_0_and_epl_1_0-796bf8d7-f485-3520-923d-e6a4b1ecd2f3 mpl-2.0 AND epl-1.0 MPL-2.0 AND EPL-1.0
URL Start line End line
https://h2database.com/html/license.html 3 3
Package URL License Primary language
pkg:osgi/com.h2database.source@2.2.220