> ## Documentation Index
> Fetch the complete documentation index at: https://docs.projectreal.gg/llms.txt
> Use this file to discover all available pages before exploring further.

# getconnections

> RBXScriptSignal에 대한 RealConnection closures의 array table을 반환합니다. 첫 번째 argument는 Luau type name이 RBXScriptSignal인 object여야 합니다. function은 signal의 Connect method를 읽고, temporary blank callback을 연결한 뒤, 임시 connection의 next reference에서 시작하는 linked list를 읽고, 임시 connection을 끊은 다음 유효한 각 connection reference를 closure로 감쌉니다. 임시 connection 뒤에 connection reference가 없으면 빈 table을 반환합니다. 이전에 감싼 underlying references는 같은 cached closure table을 반환할 수 있습니다. getsignals와 get_signal_cons는 같은 function의 aliases입니다.

<div className="real-function-page">
  ```lua theme={null}
  getconnections(signal: RBXScriptSignal): {RealConnection}
  ```

  ## 별칭

  * `getsignals`
  * `get_signal_cons`

  ## 인수

  <ParamField path={"signal"} type={"RBXScriptSignal"} required>
    검사할 signal입니다. RBXScriptSignal이 아닌 object는 type error를 발생시키고, 호출 가능한 Connect field가 없는 signal은 "Signal does not have 'Connect' method"를 발생시킵니다.
  </ParamField>

  ## 반환값

  <ResponseField name={"connections"} type={"{RealConnection}"}>
    connection closure tables의 array table입니다. 각 closure는 methods을 통해 fields와 methods를 노출하며, 사용 가능한 경우 Enabled, Disabled, LuaConnection, ForeignState, Function, Thread, Disconnect, Disable, Enable, Fire, Defer를 포함합니다.
  </ResponseField>

  ## 예제

  Inspect an RBXScriptSignal and list the wrapped connections Real can expose.

  ```lua theme={null}
  local Players = game:GetService("Players")

  for _, connection in ipairs(getconnections(Players.PlayerAdded)) do
      print(connection.Enabled, connection.LuaConnection)
  end
  ```
</div>
