All Downloads are FREE. Search and download functionalities are using the official Maven repository.

org.jdbcdslog.LogMetaData Maven / Gradle / Ivy

package org.jdbcdslog;

import java.util.concurrent.atomic.AtomicInteger;

/**
 * Log-related Meta Data for connection
 */
public class LogMetaData {
    // Currently using an integer as ID, but can be changed later with other strategy
    private static final AtomicInteger idCounter= new AtomicInteger(0);

    private String connectionId;

    public static LogMetaData create() {
        int id = idCounter.incrementAndGet();
        return new LogMetaData(String.valueOf(id));
    }

    private LogMetaData(String connectionId) {
        this.connectionId = connectionId;
    }

    public String getConnectionId() {
        return connectionId;
    }

}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy