scala / 3.1 / scala / proxy.html

Trait scala.Proxy

@deprecated("Explicitly override hashCode, equals and toString instead.", "2.13.0")
trait Proxy

This class implements a simple proxy that forwards all calls to the public, non-final methods defined in class Any to another object self. Those methods are:

def hashCode(): Int
def equals(other: Any): Boolean
def toString(): String

Note: forwarding methods in this way will most likely create an asymmetric equals method, which is not generally recommended.

Deprecated
Supertypes
Known subtypes
19 types

Abstract methods

Source
def self: Any

Concrete methods

Source
override def equals(that: Any): Boolean

Definition Classes Any

Source
override def hashCode: Int

Definition Classes Any

Source
override def toString: String

Definition Classes Any

© 2002-2022 EPFL, with contributions from Lightbend.
Licensed under the Apache License, Version 2.0.
https://scala-lang.org/api/3.1.1/scala/Proxy.html