Skip to main content
Glama

MCP Xcode

by Stefan-Nitu
ShutdownResult.ts1.66 kB
/** * Domain entity representing the result of a shutdown operation */ // Error types specific to shutdown operations export abstract class ShutdownError extends Error {} export class SimulatorNotFoundError extends ShutdownError { constructor(public readonly deviceId: string) { super(deviceId); this.name = 'SimulatorNotFoundError'; } } export class ShutdownCommandFailedError extends ShutdownError { constructor(public readonly stderr: string) { super(stderr); this.name = 'ShutdownCommandFailedError'; } } // Possible outcomes of a shutdown operation export enum ShutdownOutcome { Shutdown = 'shutdown', AlreadyShutdown = 'already_shutdown', Failed = 'failed' } // Diagnostics information about the shutdown operation interface ShutdownDiagnostics { simulatorId?: string; simulatorName?: string; error?: Error; } export class ShutdownResult { private constructor( public readonly outcome: ShutdownOutcome, public readonly diagnostics: ShutdownDiagnostics ) {} static shutdown(simulatorId: string, simulatorName: string): ShutdownResult { return new ShutdownResult( ShutdownOutcome.Shutdown, { simulatorId, simulatorName } ); } static alreadyShutdown(simulatorId: string, simulatorName: string): ShutdownResult { return new ShutdownResult( ShutdownOutcome.AlreadyShutdown, { simulatorId, simulatorName } ); } static failed(simulatorId: string | undefined, simulatorName: string | undefined, error: Error): ShutdownResult { return new ShutdownResult( ShutdownOutcome.Failed, { simulatorId, simulatorName, error } ); } }

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/Stefan-Nitu/mcp-xcode'

If you have feedback or need assistance with the MCP directory API, please join our Discord server