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

com.dynatrace.buildtools.graalnative.DynatraceProperties Maven / Gradle / Ivy

The newest version!
package com.dynatrace.buildtools.graalnative;

import java.util.Optional;
import java.util.Properties;

public final class DynatraceProperties {

	public static final String DYNATRACE_PREPARED_AGENT_DIR_PROPERTY_NAME = "dynatrace.agent.preparedDir";

	public static final String DYNATRACE_AGENT_DIR_PROPERTY_NAME = "dynatrace.agent.dir";
	public static final String DYNATRACE_AGENT_ZIP_PROPERTY_NAME = "dynatrace.agent.zip";
	public static final String DYNATRACE_AGENT_OPTIONS_PROPERTY_NAME = "dynatrace.agent.options";

	private final Properties projectProperties;

	public DynatraceProperties(final Properties projectProperties) {
		this.projectProperties = projectProperties;
	}

	public Optional getPreparedAgentDir() {
		return Optional.ofNullable(projectProperties.getProperty(DYNATRACE_PREPARED_AGENT_DIR_PROPERTY_NAME));
	}

	public void setPreparedAgentDir(final String value) {
		projectProperties.setProperty(DYNATRACE_PREPARED_AGENT_DIR_PROPERTY_NAME, value);
	}

	public Optional getAgentDir() {
		return Optional.ofNullable(projectProperties.getProperty(DYNATRACE_AGENT_DIR_PROPERTY_NAME));
	}

	public Optional getAgentZip() {
		return Optional.ofNullable(projectProperties.getProperty(DYNATRACE_AGENT_ZIP_PROPERTY_NAME));
	}

	public void setAgentOptions(final String value) {
		projectProperties.setProperty(DYNATRACE_AGENT_OPTIONS_PROPERTY_NAME, value);
	}
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy