---
title: "rootProxyForConnectionWithRegisteredName:host:usingNameServer:"
framework: foundation
role: symbol
role_heading: Type Method
path: "foundation/nsconnection/rootproxyforconnectionwithregisteredname:host:usingnameserver:"
---

# rootProxyForConnectionWithRegisteredName:host:usingNameServer:

Returns a proxy for the root object of the NSConnection object registered with server under name on a given host.

## Declaration

```occ
+ (NSDistantObject *) rootProxyForConnectionWithRegisteredName:(NSString *) name host:(NSString *) hostName usingNameServer:(NSPortNameServer *) server;
```

## Parameters

- `name`: The name of an NSConnection object .
- `hostName`: A host name.
- `server`: The server.

## Return Value

Return Value A proxy for the root object of the NSConnection object registered with server under name on the host named hostName, or nil if that NSConnection object has no root object set.

## Discussion

Discussion See rootProxyForConnectionWithRegisteredName:host: for more information.

## See Also

### Getting a Remote Object

- [connectionWithRegisteredName:host:](foundation/nsconnection/connectionwithregisteredname:host:.md)
- [connectionWithRegisteredName:host:usingNameServer:](foundation/nsconnection/connectionwithregisteredname:host:usingnameserver:.md)
- [rootProxy](foundation/nsconnection/rootproxy.md)
- [rootProxyForConnectionWithRegisteredName:host:](foundation/nsconnection/rootproxyforconnectionwithregisteredname:host:.md)
- [remoteObjects](foundation/nsconnection/remoteobjects.md)
- [localObjects](foundation/nsconnection/localobjects.md)
