Class AbstractSuppressIntrospector
- java.lang.Object
-
- nl.tudelft.simulation.introspection.AbstractSuppressIntrospector
-
- All Implemented Interfaces:
Introspector
public abstract class AbstractSuppressIntrospector extends Object implements Introspector
The AbstractSupressIntrospector.Copyright (c) 2002-2023 Delft University of Technology, Jaffalaan 5, 2628 BX Delft, the Netherlands. All rights reserved. See for project information https://simulation.tudelft.nl. The DSOL project is distributed under a three-clause BSD-style license, which can be found at https://https://simulation.tudelft.nl/dsol/docs/latest/license.html.
- Since:
- 1.5
- Author:
- Peter Jacobs , Alexander Verbraeck, Niels Lang.
-
-
Field Summary
Fields Modifier and Type Field Description protected Introspectorparentthe parent introspector.
-
Constructor Summary
Constructors Constructor Description AbstractSuppressIntrospector(Introspector parent)Constructor for AbstractSuppressIntrospector.
-
Method Summary
All Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description Property[]getProperties(Object arg0)PropertygetProperty(Object arg0, String arg1)Retrieves the {see Property}with a given name from an introspected object.String[]getPropertyNames(Object arg0)Retrieves the names of the properties of the introspected object.protected booleansuppress(Class<?> type)Method suppress.protected abstract booleansuppress(String propertyName)Method suppress.
-
-
-
Field Detail
-
parent
protected Introspector parent
the parent introspector.
-
-
Constructor Detail
-
AbstractSuppressIntrospector
public AbstractSuppressIntrospector(Introspector parent)
Constructor for AbstractSuppressIntrospector.- Parameters:
parent- Introspector; the parent introspector
-
-
Method Detail
-
getProperties
public Property[] getProperties(Object arg0)
- Specified by:
getPropertiesin interfaceIntrospector- Parameters:
arg0- Object; the introspected object- Returns:
- Retrieves properties of the introspected object. The properties' values can themselves be introspectable. An empty array is returned if no introspected object has been set.
-
getPropertyNames
public String[] getPropertyNames(Object arg0)
Retrieves the names of the properties of the introspected object.- Specified by:
getPropertyNamesin interfaceIntrospector- Parameters:
arg0- Object; The introspected object.- Returns:
- An unordered array of the introspected object's property names.
-
getProperty
public Property getProperty(Object arg0, String arg1)
Retrieves the {see Property}with a given name from an introspected object.- Specified by:
getPropertyin interfaceIntrospector- Parameters:
arg0- Object; The introspected object.arg1- String; The name of the property to be retrieved- Returns:
- A {see Property}instance for the given object and property name.
-
suppress
protected boolean suppress(Class<?> type)
Method suppress.- Parameters:
type- Class<?>; the type of the class- Returns:
- boolean whether to supress
-
suppress
protected abstract boolean suppress(String propertyName)
Method suppress.- Parameters:
propertyName- String; the propertyName- Returns:
- whether to supress
-
-