# ProxyBuilder.ProxyReference

`com.jsmacrosce.jsmacros.core.library.impl.classes.ProxyBuilder.ProxyReference`

Holds the proxy instance and a callable for the overridden method, and is passed to handlers
registered with [addMethod](ProxyBuilder.md#com.jsmacrosce.jsmacros.core.library.impl.classes.ProxyBuilder_addMethod-String-MethodWrapper-).

## Type Parameters

- `T`: the proxy instance type

Nested type declared in [ProxyBuilder](ProxyBuilder.md).

## Constructors

### new ProxyBuilder.ProxyReference {#com.jsmacrosce.jsmacros.core.library.impl.classes.ProxyBuilder.ProxyReference_constructor-T-Function-}

```js
new ProxyBuilder.ProxyReference(T self, Function<Object[], Object> parent)
```

Creates the handler reference for a proxy instance and its overridden method.

**Parameters:**
- `self`: the instance the method was called on
- `parent`: calls the method the proxy took over, or `null` when the superclass
              has no such method

## Fields

### parent {#com.jsmacrosce.jsmacros.core.library.impl.classes.ProxyBuilder.ProxyReference_parent}

```js
parent: Function<Object[], Object>
```

Calls the overridden method with the supplied arguments and returns its result, or is
`null` when there is no superclass method to invoke.

### self {#com.jsmacrosce.jsmacros.core.library.impl.classes.ProxyBuilder.ProxyReference_self}

```js
self: T
```

The proxy instance on which the intercepted method was called.
