Class VersionMask
- java.lang.Object
-
- com._1c.g5.v8.dt.platform.services.model.VersionMask
-
public final class VersionMask extends Object
Utility methods to work with masks of 1C:Enterprise version. Version masks areString
objects that are reference to 1C:Enterprise Runtime version or versions range.Examples of version masks:
- 8.3.8.1974
- 8.3.9.1235
- 8.3.9
- 8.3
InfobaseReference
contains two version masks ingetVersion()
andgetDefaultgetVersion()
fields.- See Also:
InfobaseReference
- Restriction:
- This class is not intended to be sub-classed by clients.
- Restriction:
- This class is not intended to be instantiated by clients.
-
-
Constructor Summary
Constructors Constructor Description VersionMask()
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static int
compare(String mask, String other)
Compare two version masks.static boolean
includes(String mask, String other)
Returns whether the first version mask includes second or equals to second.
-
-
-
Method Detail
-
compare
public static int compare(String mask, String other)
Compare two version masks. Method implementsComparable.compareTo(Object)
contract with next rules:- Compares
String
version masks asint
versions parts, segment by segment. - Mask with lesser segment count is greater.
- Parameters:
mask
- the first mask to compare, cannot benull
other
- the second mask to compare, cannot benull
- Returns:
- whetehr fist mask is greater than second
- Compares
-
includes
public static boolean includes(String mask, String other)
Returns whether the first version mask includes second or equals to second.- Parameters:
mask
- the first mask to check, cannot benull
other
- the second mask to check, cannot benull
- Returns:
- whether the first version mask includes second or equals to second
-
-