Package io.papermc.asm.rules.method
Record Class StaticRewrites.FuzzyParam
java.lang.Object
java.lang.Record
io.papermc.asm.rules.method.StaticRewrites.FuzzyParam
- All Implemented Interfaces:
GeneratedMethodHolder,GeneratedMethodSource<Set<Integer>>,StaticRewriteGeneratedMethodHolder,StaticRewriteGeneratedMethodHolder.Param,FilteredMethodRewriteRule,MethodRewriteRule,StaticRewrite,StaticRewrite.Generated,StaticRewrite.Generated.Param,OwnableRewriteRule,RewriteRule
- Enclosing class:
- StaticRewrites
public static record StaticRewrites.FuzzyParam(Set<Class<?>> owners, ClassDesc existingType, TargetedMethodMatcher methodMatcher, ClassDesc generatedMethodOwner, Method staticHandler)
extends Record
implements StaticRewrite.Generated.Param
-
Nested Class Summary
Nested classes/interfaces inherited from interface io.papermc.asm.rules.generate.GeneratedMethodSource
GeneratedMethodSource.NoContextNested classes/interfaces inherited from interface io.papermc.asm.rules.method.MethodRewriteRule
MethodRewriteRule.Rewrite, MethodRewriteRule.RewriteSingleNested classes/interfaces inherited from interface io.papermc.asm.rules.RewriteRule
RewriteRule.Chain, RewriteRule.ChainBuilder, RewriteRule.MethodGeneratorFactoryNested classes/interfaces inherited from interface io.papermc.asm.rules.method.StaticRewrite
StaticRewrite.Generated, StaticRewrite.Plain, StaticRewrite.RewriteConstructorNested classes/interfaces inherited from interface io.papermc.asm.rules.method.StaticRewrite.Generated
StaticRewrite.Generated.Param, StaticRewrite.Generated.ReturnNested classes/interfaces inherited from interface io.papermc.asm.rules.generate.StaticRewriteGeneratedMethodHolder
StaticRewriteGeneratedMethodHolder.Param, StaticRewriteGeneratedMethodHolder.Return -
Field Summary
Fields inherited from interface io.papermc.asm.rules.method.MethodRewriteRule
LAMBDA_METAFACTORY_OWNERFields inherited from interface io.papermc.asm.rules.RewriteRule
EMPTYFields inherited from interface io.papermc.asm.rules.method.StaticRewrite
CONSTRUCTOR_METHOD_NAME -
Constructor Summary
ConstructorsConstructorDescriptionFuzzyParam(Set<Class<?>> owners, ClassDesc existingType, TargetedMethodMatcher methodMatcher, ClassDesc generatedMethodOwner, Method staticHandler) Creates an instance of aFuzzyParamrecord class. -
Method Summary
Modifier and TypeMethodDescriptioncomputeGeneratedDescriptor(MethodTypeDesc existing, Set<Integer> context) Modifies the descriptor for the actual method for the generated method.final booleanIndicates whether some other object is "equal to" this one.Returns the value of theexistingTyperecord component.Returns the value of thegeneratedMethodOwnerrecord component.final inthashCode()Returns a hash code value for this object.Returns the value of themethodMatcherrecord component.modifyMethodDescriptor(MethodTypeDesc bytecodeDescriptor) owners()Returns the value of theownersrecord component.Returns the value of thestaticHandlerrecord component.final StringtoString()Returns a string representation of this record class.Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, waitMethods inherited from interface io.papermc.asm.rules.method.FilteredMethodRewriteRule
matchingMethodsByName, shouldProcessMethods inherited from interface io.papermc.asm.rules.generate.GeneratedMethodHolder
staticRedirectOwnerMethods inherited from interface io.papermc.asm.rules.generate.GeneratedMethodSource
generateMethod, generateReturnValueMethods inherited from interface io.papermc.asm.rules.method.MethodRewriteRule
createVisitorMethods inherited from interface io.papermc.asm.rules.OwnableRewriteRule
matchesOwnerMethods inherited from interface io.papermc.asm.rules.method.StaticRewrite
rewriteMethods inherited from interface io.papermc.asm.rules.method.StaticRewrite.Generated
generateMethods, staticRedirectOwnerMethods inherited from interface io.papermc.asm.rules.method.StaticRewrite.Generated.Param
matchesExistingMethodMethods inherited from interface io.papermc.asm.rules.generate.StaticRewriteGeneratedMethodHolder.Param
createNewContext, generateParameters
-
Constructor Details
-
FuzzyParam
public FuzzyParam(Set<Class<?>> owners, ClassDesc existingType, TargetedMethodMatcher methodMatcher, ClassDesc generatedMethodOwner, Method staticHandler) Creates an instance of aFuzzyParamrecord class.- Parameters:
owners- the value for theownersrecord componentexistingType- the value for theexistingTyperecord componentmethodMatcher- the value for themethodMatcherrecord componentgeneratedMethodOwner- the value for thegeneratedMethodOwnerrecord componentstaticHandler- the value for thestaticHandlerrecord component
-
-
Method Details
-
modifyMethodDescriptor
- Specified by:
modifyMethodDescriptorin interfaceStaticRewrite
-
computeGeneratedDescriptor
Description copied from interface:GeneratedMethodSourceModifies the descriptor for the actual method for the generated method.- Specified by:
computeGeneratedDescriptorin interfaceGeneratedMethodSource<Set<Integer>>- Parameters:
existing- the original (in source) method descriptorcontext- context for the generator- Returns:
- the modified descriptor
-
toString
Returns a string representation of this record class. The representation contains the name of the class, followed by the name and value of each of the record components. -
hashCode
public final int hashCode()Returns a hash code value for this object. The value is derived from the hash code of each of the record components. -
equals
Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. All components in this record class are compared withObjects::equals(Object,Object). -
owners
Returns the value of theownersrecord component.- Specified by:
ownersin interfaceOwnableRewriteRule- Returns:
- the value of the
ownersrecord component
-
existingType
Returns the value of theexistingTyperecord component.- Specified by:
existingTypein interfaceStaticRewrite.Generated- Returns:
- the value of the
existingTyperecord component
-
methodMatcher
Returns the value of themethodMatcherrecord component.- Specified by:
methodMatcherin interfaceFilteredMethodRewriteRule- Returns:
- the value of the
methodMatcherrecord component
-
generatedMethodOwner
Returns the value of thegeneratedMethodOwnerrecord component.- Specified by:
generatedMethodOwnerin interfaceGeneratedMethodHolder- Returns:
- the value of the
generatedMethodOwnerrecord component
-
staticHandler
Returns the value of thestaticHandlerrecord component.- Specified by:
staticHandlerin interfaceStaticRewriteGeneratedMethodHolder- Returns:
- the value of the
staticHandlerrecord component
-