Quartz UI ↗
Browse docs
On this page
Private preview · 0.57.0-devView Markdown

QuartzUIDevelopmentPolicy: declaration reference

0.57.0-dev · beta source documentation. Native, Blueprint, Editor and rendering examples are source-reviewed, not executed in Unreal during this scan. See validation and limits.

Pinned source (source: Source/QuartzUIRuntime/Public/QuartzUIDevelopmentPolicy.h) · integration recipe · practical guide

FQuartzUIDevelopmentEndpoint

Internal type. Validated Editor-only mapping from one packaged app ID to one Vite origin.

Prerequisites / integration: Installed source plugin; Editor tools additionally require a compiled compatible host Editor target. Use the QuartzUIDevelopmentPolicy recipe in the host module QuartzUIRuntime.

Minimal example / lifecycle: Use Editor-owned Vite Start/Stop workflow. Registry entry lives only while approved editor process is active.

Avoid: Shipping loopback overrides or accepting arbitrary remote URLs. This named helper is runtime-owned; inspect/use it through the owner above rather than constructing it in gameplay.

Exact source line (source: Source/QuartzUIRuntime/Public/QuartzUIDevelopmentPolicy.h#L6)

FQuartzUIDevelopmentPolicy

Internal type. Pure bounded policy for development URLs; it never launches or owns a process.

Prerequisites / integration: Installed source plugin; Editor tools additionally require a compiled compatible host Editor target. Use the QuartzUIDevelopmentPolicy recipe in the host module QuartzUIRuntime.

Minimal example / lifecycle: Use Editor-owned Vite Start/Stop workflow. Registry entry lives only while approved editor process is active.

Avoid: Shipping loopback overrides or accepting arbitrary remote URLs. This named helper is runtime-owned; inspect/use it through the owner above rather than constructing it in gameplay.

Exact source line (source: Source/QuartzUIRuntime/Public/QuartzUIDevelopmentPolicy.h#L16)

FQuartzUIDevelopmentRegistry

Internal type. Process-local Editor override. Packaged builds compile out this registry and all callers.

Prerequisites / integration: Installed source plugin; Editor tools additionally require a compiled compatible host Editor target. Use the QuartzUIDevelopmentPolicy recipe in the host module QuartzUIRuntime.

Minimal example / lifecycle: Use Editor-owned Vite Start/Stop workflow. Registry entry lives only while approved editor process is active.

Avoid: Shipping loopback overrides or accepting arbitrary remote URLs. This named helper is runtime-owned; inspect/use it through the owner above rather than constructing it in gameplay.

Exact source line (source: Source/QuartzUIRuntime/Public/QuartzUIDevelopmentPolicy.h#L35)

Complete header

Source snapshot, not an additional example. Unreal annotations distinguish exposed Blueprint nodes from native-only/private methods.

#pragma once

#include "CoreMinimal.h"

/** Validated Editor-only mapping from one packaged app ID to one Vite origin. */
struct QUARTZUIRUNTIME_API FQuartzUIDevelopmentEndpoint
{
	FName AppId;
	int32 Port = 0;
	FString EntryPath;
	FString Origin;
	FString Url;
};

/** Pure bounded policy for development URLs; it never launches or owns a process. */
class QUARTZUIRUNTIME_API FQuartzUIDevelopmentPolicy final
{
public:
	static constexpr int32 MinPort = 1024;
	static constexpr int32 MaxPort = 65535;
	static constexpr int32 MaxUrlLength = 2048;

	static bool TryBuildEndpoint(
		FName AppId,
		int32 Port,
		const FString& EntryPath,
		FQuartzUIDevelopmentEndpoint& OutEndpoint,
		FString& OutError);
	static bool IsValidOrigin(const FString& Origin);
	static bool IsUrlAllowed(const FString& Url, const FString& AllowedOrigin);
};

#if WITH_EDITOR
/** Process-local Editor override. Packaged builds compile out this registry and all callers. */
class QUARTZUIRUNTIME_API FQuartzUIDevelopmentRegistry final
{
public:
	static bool Activate(const FQuartzUIDevelopmentEndpoint& Endpoint, FString& OutError);
	static void Deactivate();
	static bool TryGetActive(FName AppId, FQuartzUIDevelopmentEndpoint& OutEndpoint);
	static bool IsOriginActive(const FString& Origin);
};
#endif