public class SizeValue extends Object
Constructor and Description |
---|
SizeValue(String valueParam)
Create a new instance using the given value.
|
Modifier and Type | Method and Description |
---|---|
float |
getValue(float range)
Get the value as float.
|
int |
getValueAsInt(float range)
Get the value as int.
|
boolean |
hasHeightSuffix() |
boolean |
hasWidthSuffix() |
boolean |
hasWildcard() |
boolean |
isPercentOrPixel()
Checks if the value contains either PERCENT or PIXEL.
|
boolean |
isPixel()
Checks if this value describes a pixel value.
|
String |
toString()
toString.
|
public SizeValue(String valueParam)
valueParam
- the String valuepublic boolean isPercentOrPixel()
public float getValue(float range)
range
- the size that percent values are calculated from.public int getValueAsInt(float range)
range
- range the size that percent values are calculated from.public boolean isPixel()
public boolean hasWidthSuffix()
public boolean hasHeightSuffix()
public boolean hasWildcard()
Copyright © 2013. All Rights Reserved.