Search in sources :

Example 6 with StoreProviderTransaction

use of com.djrapitops.plan.extension.implementation.storage.transactions.providers.StoreProviderTransaction in project Plan by plan-player-analytics.

the class DataValueGatherer method storeString.

private void storeString(Parameters parameters, Conditions conditions, StringDataValue data) {
    ProviderInformation information = data.getInformation();
    String value = getValue(conditions, data, information);
    if (value == null)
        return;
    Database db = dbSystem.getDatabase();
    db.executeTransaction(new StoreIconTransaction(information.getIcon()));
    db.executeTransaction(new StoreProviderTransaction(information, parameters));
    db.executeTransaction(new StoreServerStringResultTransaction(information, parameters, value));
}
Also used : StoreIconTransaction(com.djrapitops.plan.extension.implementation.storage.transactions.StoreIconTransaction) StoreProviderTransaction(com.djrapitops.plan.extension.implementation.storage.transactions.providers.StoreProviderTransaction) Database(com.djrapitops.plan.storage.database.Database) ProviderInformation(com.djrapitops.plan.extension.implementation.ProviderInformation)

Example 7 with StoreProviderTransaction

use of com.djrapitops.plan.extension.implementation.storage.transactions.providers.StoreProviderTransaction in project Plan by plan-player-analytics.

the class DataValueGatherer method storePlayerDouble.

private void storePlayerDouble(Parameters parameters, Conditions conditions, DoubleDataValue data) {
    ProviderInformation information = data.getInformation();
    Double value = getValue(conditions, data, information);
    if (value == null)
        return;
    Database db = dbSystem.getDatabase();
    db.executeTransaction(new StoreIconTransaction(information.getIcon()));
    db.executeTransaction(new StoreProviderTransaction(information, parameters));
    db.executeTransaction(new StorePlayerDoubleResultTransaction(information, parameters, value));
}
Also used : StoreIconTransaction(com.djrapitops.plan.extension.implementation.storage.transactions.StoreIconTransaction) StoreProviderTransaction(com.djrapitops.plan.extension.implementation.storage.transactions.providers.StoreProviderTransaction) Database(com.djrapitops.plan.storage.database.Database) ProviderInformation(com.djrapitops.plan.extension.implementation.ProviderInformation)

Example 8 with StoreProviderTransaction

use of com.djrapitops.plan.extension.implementation.storage.transactions.providers.StoreProviderTransaction in project Plan by plan-player-analytics.

the class DataValueGatherer method storePlayerNumber.

private void storePlayerNumber(Parameters parameters, Conditions conditions, NumberDataValue data) {
    ProviderInformation information = data.getInformation();
    Long value = getValue(conditions, data, information);
    if (value == null)
        return;
    Database db = dbSystem.getDatabase();
    db.executeTransaction(new StoreIconTransaction(information.getIcon()));
    db.executeTransaction(new StoreProviderTransaction(information, parameters));
    db.executeTransaction(new StorePlayerNumberResultTransaction(information, parameters, value));
}
Also used : StoreIconTransaction(com.djrapitops.plan.extension.implementation.storage.transactions.StoreIconTransaction) StoreProviderTransaction(com.djrapitops.plan.extension.implementation.storage.transactions.providers.StoreProviderTransaction) Database(com.djrapitops.plan.storage.database.Database) ProviderInformation(com.djrapitops.plan.extension.implementation.ProviderInformation)

Example 9 with StoreProviderTransaction

use of com.djrapitops.plan.extension.implementation.storage.transactions.providers.StoreProviderTransaction in project Plan by plan-player-analytics.

the class DataValueGatherer method storePlayerString.

private void storePlayerString(Parameters parameters, Conditions conditions, StringDataValue data) {
    ProviderInformation information = data.getInformation();
    String value = getValue(conditions, data, information);
    if (value == null)
        return;
    Database db = dbSystem.getDatabase();
    db.executeTransaction(new StoreIconTransaction(information.getIcon()));
    db.executeTransaction(new StoreProviderTransaction(information, parameters));
    db.executeTransaction(new StorePlayerStringResultTransaction(information, parameters, value));
}
Also used : StoreIconTransaction(com.djrapitops.plan.extension.implementation.storage.transactions.StoreIconTransaction) StoreProviderTransaction(com.djrapitops.plan.extension.implementation.storage.transactions.providers.StoreProviderTransaction) Database(com.djrapitops.plan.storage.database.Database) ProviderInformation(com.djrapitops.plan.extension.implementation.ProviderInformation)

Aggregations

ProviderInformation (com.djrapitops.plan.extension.implementation.ProviderInformation)9 StoreIconTransaction (com.djrapitops.plan.extension.implementation.storage.transactions.StoreIconTransaction)9 StoreProviderTransaction (com.djrapitops.plan.extension.implementation.storage.transactions.providers.StoreProviderTransaction)9 Database (com.djrapitops.plan.storage.database.Database)9