feat(studio): refine Play workspace and project preferences (WRK-001D)
Test / Tests and coverage
Intrepid/Prometeu/Studio/pipeline/head This commit looks good

This commit is contained in:
2026-11-22 15:45:09 +00:00
parent f27cecfe39
commit 2d8f6436e4
42 changed files with 1597 additions and 169 deletions
@@ -0,0 +1,15 @@
package p.studio.api.preferences;
/** Machine-local Studio default, separate from frontend appearance and project overrides. */
public interface RuntimeSettingsStore {
String load();
void save(String installation);
/** Validate a nonempty installation without starting a runtime. Implementations perform IO off the UI thread. */
default void validate(String installation) { }
default String resolve(String projectOverride) {
String effective = projectOverride == null || projectOverride.isBlank() ? load() : projectOverride.trim();
if (effective == null || effective.isBlank()) throw new IllegalArgumentException("Runtime installation is missing");
validate(effective);
return effective;
}
}
@@ -5,6 +5,10 @@ import p.studio.api.project.ProjectReference;
import java.util.Optional;
public interface WindowStateStore {
default Optional<WindowGeometry> loadLauncher() { return Optional.empty(); }
default void saveLauncher(WindowGeometry geometry) { }
Optional<WindowGeometry> load(ProjectReference projectReference);
void save(ProjectReference projectReference, WindowGeometry geometry);
@@ -7,4 +7,10 @@ import java.util.function.Consumer;
public interface Shipper {
OperationHandle<ShipperPrepareResult> prepare(ProjectReference project, Consumer<ShipperLogEntry> logSink);
/** Freeze the selected execution configuration for interactive build admission without persisting inherited defaults. */
default OperationHandle<ShipperPrepareResult> prepare(ProjectReference project,
p.studio.api.project.ProjectLocalStudioSetup effectiveSetup, Consumer<ShipperLogEntry> logSink) {
return prepare(project,logSink);
}
}