/** * Get the target profile to upload contents. * If the DeploymentManager was not loaded, the * default key is used. * * @return the target profile key */ protected ProfileKey getTargetProfile() { if(this.activeProfileKey.get() == null) return this.defaultKey; ProfileKey active = this.activeProfileKey.get(); if(active.isDefaultKey()) return this.defaultKey; return active; }
public void loadProfile(ProfileKey key) throws NoSuchProfileException { // Override a DEFAULT key with the injected default if(key.isDefaultKey() && this.defaultKey != null) key = this.defaultKey; // Check if we have a associated DeploymentRepository checkProfile(key); // Set the key this.activeProfileKey.set(key); }