ServiceProvider

ServiceProvider : Instance

Overview

An abstract base class that returns service Objects such as Workspace or Players

Properties

Methods

FindService

If a service with the specified name exists, it returns that service.

If the name is incorrect or the service hasn't been created yet, an error will occur.

Parameters

string InClassName

The class name of the service to retrieve.

Return

Instance

Code Samples

GetService

If a service with the specified name exists, it returns that service.

If the provided name corresponds to a valid service, it returns the service if it already exists; if not, the service is automatically created and returned.

Parameters

string InClassName

The class name of the service to retrieve.

Return

Instance

Code Samples

Events

See also

Object Reference

Last updated