Class Version
- java.lang.Object
-
- com.aoindustries.aoserv.client.AOServObject<K,T>
-
- com.aoindustries.aoserv.client.GlobalObject<Integer,T>
-
- com.aoindustries.aoserv.client.GlobalObjectIntegerKey<Version>
-
- com.aoindustries.aoserv.client.postgresql.Version
-
- All Implemented Interfaces:
Streamable,StreamReadable,StreamWritable,Row,AOServReadable,AOServStreamable,AOServWritable
public final class Version extends GlobalObjectIntegerKey<Version>
APostgresVersionflags whichTechnologyVersions are a version of PostgreSQL.- Author:
- AO Industries, Inc.
- See Also:
Server,SoftwareVersion
-
-
Field Summary
Fields Modifier and Type Field Description static StringTECHNOLOGY_NAMEstatic StringVERSION_10static StringVERSION_11static StringVERSION_12static StringVERSION_13static StringVERSION_7_1static StringVERSION_7_2static StringVERSION_7_3static StringVERSION_8_0static StringVERSION_8_1static StringVERSION_8_3static StringVERSION_9_2static StringVERSION_9_4static StringVERSION_9_5static StringVERSION_9_6-
Fields inherited from class com.aoindustries.aoserv.client.GlobalObjectIntegerKey
pkey
-
Fields inherited from class com.aoindustries.aoserv.client.AOServObject
USE_ARRAY_OF_DOMAIN, USE_SQL_DATA, USE_SQL_DATA_WRITE
-
-
Constructor Summary
Constructors Constructor Description Version()
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description protected ObjectgetColumnImpl(int i)StringgetMinorVersion()SoftwareVersiongetPostgisVersion(AOServConnector connector)Gets the PostGIS version ofnullif not supported by this PostgreSQL version....EncodinggetPostgresEncoding(AOServConnector connector, String encoding)List<Encoding>getPostgresEncodings(AOServConnector connector)static String[]getPreferredMinorVersions()Gets the versions of PostgreSQL in order of preference.Table.TableIDgetTableID()SoftwareVersiongetTechnologyVersion(AOServConnector connector)voidinit(ResultSet result)Initializes this object from the raw database contents.booleanisScramSha256(AOServConnector connector)static booleanisScramSha256(String version)Checks if a version of PostgreSQL supports scram-sha-256 authentication.voidread(StreamableInput in, AoservProtocol.Version protocolVersion)voidwrite(StreamableOutput out, AoservProtocol.Version protocolVersion)-
Methods inherited from class com.aoindustries.aoserv.client.GlobalObjectIntegerKey
equals, getKey, getPkey, hashCode, toStringImpl
-
Methods inherited from class com.aoindustries.aoserv.client.AOServObject
compare, compare, compare, compare, compareIgnoreCaseConsistentWithEquals, compareTo, compareTo, compareTo, getAccountingCode, getColumn, getColumns, getColumns, getDomainLabel, getDomainLabels, getDomainName, getDto, getEmail, getGecos, getGroupId, getHashedKey, getHashedPassword, getHostname, getInetAddress, getLinuxID, getLinuxUserName, getMacAddress, getMySQLDatabaseName, getMySQLServerName, getMysqlUserName, getPort, getPostgresDatabaseName, getPostgresServerName, getPostgresUserId, getTableSchema, getTimeMillis, getTimeMillis, getUnixPath, getUserId, read, toString, write
-
-
-
-
Field Detail
-
TECHNOLOGY_NAME
public static final String TECHNOLOGY_NAME
- See Also:
- Constant Field Values
-
VERSION_7_1
public static final String VERSION_7_1
- See Also:
- Constant Field Values
-
VERSION_7_2
public static final String VERSION_7_2
- See Also:
- Constant Field Values
-
VERSION_7_3
public static final String VERSION_7_3
- See Also:
- Constant Field Values
-
VERSION_8_0
public static final String VERSION_8_0
- See Also:
- Constant Field Values
-
VERSION_8_1
public static final String VERSION_8_1
- See Also:
- Constant Field Values
-
VERSION_8_3
public static final String VERSION_8_3
- See Also:
- Constant Field Values
-
VERSION_9_2
public static final String VERSION_9_2
- See Also:
- Constant Field Values
-
VERSION_9_4
public static final String VERSION_9_4
- See Also:
- Constant Field Values
-
VERSION_9_5
public static final String VERSION_9_5
- See Also:
- Constant Field Values
-
VERSION_9_6
public static final String VERSION_9_6
- See Also:
- Constant Field Values
-
VERSION_10
public static final String VERSION_10
- See Also:
- Constant Field Values
-
VERSION_11
public static final String VERSION_11
- See Also:
- Constant Field Values
-
VERSION_12
public static final String VERSION_12
- See Also:
- Constant Field Values
-
VERSION_13
public static final String VERSION_13
- See Also:
- Constant Field Values
-
-
Method Detail
-
getPreferredMinorVersions
public static String[] getPreferredMinorVersions()
Gets the versions of PostgreSQL in order of preference. Index0is the most preferred.TODO: Rename "getPreferredMajorVersions
-
isScramSha256
public static boolean isScramSha256(String version)
Checks if a version of PostgreSQL supports scram-sha-256 authentication. This is added as of PostgreSQL 10.
-
getColumnImpl
protected Object getColumnImpl(int i)
- Specified by:
getColumnImplin classAOServObject<Integer,Version>
-
getMinorVersion
public String getMinorVersion()
-
getPostgisVersion
public SoftwareVersion getPostgisVersion(AOServConnector connector) throws SQLException, IOException
Gets the PostGIS version ofnullif not supported by this PostgreSQL version....- Throws:
SQLExceptionIOException
-
getTableID
public Table.TableID getTableID()
- Specified by:
getTableIDin classAOServObject<Integer,Version>
-
getPostgresEncodings
public List<Encoding> getPostgresEncodings(AOServConnector connector) throws IOException, SQLException
- Throws:
IOExceptionSQLException
-
getPostgresEncoding
public Encoding getPostgresEncoding(AOServConnector connector, String encoding) throws IOException, SQLException
- Throws:
IOExceptionSQLException
-
getTechnologyVersion
public SoftwareVersion getTechnologyVersion(AOServConnector connector) throws SQLException, IOException
- Throws:
SQLExceptionIOException
-
isScramSha256
public boolean isScramSha256(AOServConnector connector) throws SQLException, IOException
- Throws:
SQLExceptionIOException- See Also:
isScramSha256(java.lang.String)
-
init
public void init(ResultSet result) throws SQLException
Description copied from class:AOServObjectInitializes this object from the raw database contents.- Specified by:
initin classAOServObject<Integer,Version>- Parameters:
result- theResultSetcontaining the row to copy into this object- Throws:
SQLException
-
read
public void read(StreamableInput in, AoservProtocol.Version protocolVersion) throws IOException
- Specified by:
readin interfaceAOServReadable- Specified by:
readin interfaceAOServStreamable- Specified by:
readin classAOServObject<Integer,Version>- Throws:
IOException
-
write
public void write(StreamableOutput out, AoservProtocol.Version protocolVersion) throws IOException
- Specified by:
writein interfaceAOServStreamable- Specified by:
writein interfaceAOServWritable- Specified by:
writein classAOServObject<Integer,Version>- Throws:
IOException
-
-