mirror of
				https://github.com/PlaceholderAPI/PlaceholderAPI
				synced 2025-10-31 06:12:28 +01:00 
			
		
		
		
	Add back deprecated getPlaceholders method
This commit is contained in:
		| @@ -22,6 +22,7 @@ package me.clip.placeholderapi; | |||||||
|  |  | ||||||
| import com.google.common.collect.ImmutableSet; | import com.google.common.collect.ImmutableSet; | ||||||
| import java.util.List; | import java.util.List; | ||||||
|  | import java.util.Map; | ||||||
| import java.util.Set; | import java.util.Set; | ||||||
| import java.util.regex.Matcher; | import java.util.regex.Matcher; | ||||||
| import java.util.regex.Pattern; | import java.util.regex.Pattern; | ||||||
| @@ -213,6 +214,24 @@ public final class PlaceholderAPI { | |||||||
|     return setRelationalPlaceholders(one, two, text, true); |     return setRelationalPlaceholders(one, two, text, true); | ||||||
|   } |   } | ||||||
|  |  | ||||||
|  |  | ||||||
|  |   /** | ||||||
|  |    * Get map of registered placeholders | ||||||
|  |    * | ||||||
|  |    * @return Map of registered placeholders | ||||||
|  |    * @deprecated Use {@link me.clip.placeholderapi.PlaceholderAPIPlugin().getLocalExpansionManager() | ||||||
|  |    *         .getExpansions()} instead. | ||||||
|  |    */ | ||||||
|  |   @NotNull | ||||||
|  |   @Deprecated | ||||||
|  |   @ApiStatus.ScheduledForRemoval(inVersion = "2.11.0") | ||||||
|  |   public static Map<String, PlaceholderHook> getPlaceholders() | ||||||
|  |   { | ||||||
|  |     return PlaceholderAPIPlugin.getInstance().getLocalExpansionManager() | ||||||
|  |         .getExpansions().stream() | ||||||
|  |       .collect(Collectors.toMap(PlaceholderExpansion::getIdentifier, ex -> ex)); | ||||||
|  |   } | ||||||
|  |  | ||||||
|   /** |   /** | ||||||
|    * Translate placeholders in the provided list based on the relation of the two provided players. |    * Translate placeholders in the provided list based on the relation of the two provided players. | ||||||
|    * <br>The pattern of a valid placeholder is {@literal %rel_<identifier>_<params>%}. |    * <br>The pattern of a valid placeholder is {@literal %rel_<identifier>_<params>%}. | ||||||
|   | |||||||
		Reference in New Issue
	
	Block a user