Package oracle.pgx.api.expansion
Class PgqlViewGraphExpander
- java.lang.Object
-
- oracle.pgx.api.expansion.AbstractGraphExpander<PgqlViewGraphExpander>
-
- oracle.pgx.api.expansion.PgqlViewGraphExpander
-
- Direct Known Subclasses:
PreparedPgViewPgqlQuery
public class PgqlViewGraphExpander extends AbstractGraphExpander<PgqlViewGraphExpander>
Expander for PGQL-based graph expansions from either PG View or SQL Property Graphs.
-
-
Constructor Summary
Constructors Constructor Description PgqlViewGraphExpander(PartitionedGraphConfig graphConfig, PgxSession session, java.util.function.Function<oracle.pgx.api.expansion.internal.GraphExpansionConfig,PgxFuture<PgxGraph>> expansionFunction, oracle.pgx.api.subgraph.internal.KeystoreLookup keystoreLookup)Create a new expander from a base graph.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description PgqlViewGraphExpanderconnections(int numConnections)sets the number of connections to open to load the data in parallelPgqlViewGraphExpanderdataSourceId(java.lang.String dataSourceId)sets the dataSourceId to which to connectPgqlViewGraphExpanderfromPgPgql(java.lang.String pgGraphName)Expand from a (different) PG PGQL.PgqlViewGraphExpanderfromPgPgql(java.lang.String schemaName, java.lang.String pgGraphName)Expand from a (different) PG PGQL.PgqlViewGraphExpanderfromPgSql(java.lang.String sqlGraphName)Expand from a (different) SQL Property Graph.PgqlViewGraphExpanderfromPgSql(java.lang.String schemaName, java.lang.String sqlGraphName)Expand from a (different) SQL Property Graph.PgqlViewGraphExpanderjdbcUrl(java.lang.String jdbcUrl)sets the jdbcUrl to use for connecting to the DBPgqlViewGraphExpanderkeystoreAlias(java.lang.String keystoreAlias)sets the keystore alias to retrieve the password from the keystorePgqlViewGraphExpanderpassword(java.lang.String password)sets the password to use for connecting to the databasePreparedPgViewPgqlQuerypreparedPgqlQuery(java.lang.String query)Add a new prepared PGQL query to the expansion.PgqlViewGraphExpanderqueryPgql(java.lang.String query)Add a PGQL query to the expansion.PgqlViewGraphExpanderusername(java.lang.String userName)sets the username of the DB user to use to connect to the DB-
Methods inherited from class oracle.pgx.api.expansion.AbstractGraphExpander
edgePropertiesMergingStrategy, expand, expand, expandAsync, expandAsync, expandNewSnapshot, expandNewSnapshotAsync, vertexPropertiesMergingStrategy, withConfig
-
-
-
-
Constructor Detail
-
PgqlViewGraphExpander
public PgqlViewGraphExpander(PartitionedGraphConfig graphConfig, PgxSession session, java.util.function.Function<oracle.pgx.api.expansion.internal.GraphExpansionConfig,PgxFuture<PgxGraph>> expansionFunction, oracle.pgx.api.subgraph.internal.KeystoreLookup keystoreLookup)
Create a new expander from a base graph. Do not use this constructor, useGenericGraphExpander.withPgql()to acquire an instance of this class instead.- Parameters:
graphConfig- Config of the graph being expanded.session- Session calling the expand operation.expansionFunction- A function calling the actual expand operation.
-
-
Method Detail
-
fromPgPgql
public PgqlViewGraphExpander fromPgPgql(java.lang.String pgGraphName)
Expand from a (different) PG PGQL.- Parameters:
pgGraphName- The name of the graph.- Returns:
- This expander.
-
fromPgPgql
public PgqlViewGraphExpander fromPgPgql(java.lang.String schemaName, java.lang.String pgGraphName)
Expand from a (different) PG PGQL.- Parameters:
schemaName- The name of the schema.pgGraphName- The name of the graph.- Returns:
- This expander.
-
fromPgSql
public PgqlViewGraphExpander fromPgSql(java.lang.String sqlGraphName)
Expand from a (different) SQL Property Graph.- Parameters:
sqlGraphName- The SQL Graph name.- Returns:
- This expander.
-
fromPgSql
public PgqlViewGraphExpander fromPgSql(java.lang.String schemaName, java.lang.String sqlGraphName)
Expand from a (different) SQL Property Graph.- Parameters:
schemaName- The SQL Schema name.sqlGraphName- The SQL Graph name.- Returns:
- This expander.
-
queryPgql
public PgqlViewGraphExpander queryPgql(java.lang.String query)
Add a PGQL query to the expansion. Additional data matching this query will be loaded.- Parameters:
query- The query.- Returns:
- This expander.
-
preparedPgqlQuery
public PreparedPgViewPgqlQuery preparedPgqlQuery(java.lang.String query)
Add a new prepared PGQL query to the expansion. Additional data matching this query will be loaded. This returns a new builder where arguments for the query must be provided.- Parameters:
query- The query.- Returns:
- A builder where query arguments must be provided.
-
dataSourceId
public PgqlViewGraphExpander dataSourceId(java.lang.String dataSourceId)
sets the dataSourceId to which to connect- Parameters:
dataSourceId- the datasourceId- Returns:
- this loader
-
jdbcUrl
public PgqlViewGraphExpander jdbcUrl(java.lang.String jdbcUrl)
sets the jdbcUrl to use for connecting to the DB- Parameters:
jdbcUrl- the jdbc url- Returns:
- this loader
-
username
public PgqlViewGraphExpander username(java.lang.String userName)
sets the username of the DB user to use to connect to the DB- Parameters:
userName- the username- Returns:
- this loader
-
keystoreAlias
public PgqlViewGraphExpander keystoreAlias(java.lang.String keystoreAlias)
sets the keystore alias to retrieve the password from the keystore- Parameters:
keystoreAlias- the keystore alias- Returns:
- this loader
-
password
public PgqlViewGraphExpander password(java.lang.String password)
sets the password to use for connecting to the database- Parameters:
password- the password- Returns:
- this loader
-
connections
public PgqlViewGraphExpander connections(int numConnections)
sets the number of connections to open to load the data in parallel- Parameters:
numConnections- the number of connections- Returns:
- this loader
-
-