public final class XMLLimitAnalyzer extends Object
| Modifier and Type | Class and Description |
|---|---|
static class |
XMLLimitAnalyzer.NameMap
Map old property names with the new ones
|
| Constructor and Description |
|---|
XMLLimitAnalyzer()
Default constructor.
|
| Modifier and Type | Method and Description |
|---|---|
void |
addValue(int index,
String entityName,
int value)
Add the value to the current count by the index of the property
|
void |
addValue(XMLSecurityManager.Limit limit,
String entityName,
int value)
Add the value to the current max count for the specified property
To find the max value of all entities, set no limit
|
void |
debugPrint(XMLSecurityManager securityManager) |
void |
endEntity(XMLSecurityManager.Limit limit,
String name)
Stop tracking the entity
|
int |
getTotalValue(int index) |
int |
getTotalValue(XMLSecurityManager.Limit limit)
Return the total value accumulated so far
|
int |
getValue(int index) |
int |
getValue(XMLSecurityManager.Limit limit)
Return the value of the current max count for the specified property
|
int |
getValueByIndex(int index)
Return the current max value (count or length) by the index of a property
|
boolean |
isTracking(String name) |
void |
startEntity(String name) |
public XMLLimitAnalyzer()
public void addValue(XMLSecurityManager.Limit limit, String entityName, int value)
limit - the type of the propertyentityName - the name of the entityvalue - the value of the entitypublic void addValue(int index,
String entityName,
int value)
index - the index of the propertyentityName - the name of the entityvalue - the value of the entitypublic int getValue(XMLSecurityManager.Limit limit)
limit - the propertypublic int getValue(int index)
public int getTotalValue(XMLSecurityManager.Limit limit)
limit - the propertypublic int getTotalValue(int index)
public int getValueByIndex(int index)
index - the index of a propertypublic void startEntity(String name)
public boolean isTracking(String name)
public void endEntity(XMLSecurityManager.Limit limit, String name)
limit - the limit propertyname - the name of an entitypublic void debugPrint(XMLSecurityManager securityManager)
Copyright © 2018–2021 mhoffrogge. All rights reserved.