Skip to content

Latest commit

 

History

History
36 lines (25 loc) · 2.48 KB

File metadata and controls

36 lines (25 loc) · 2.48 KB

subkt / myaa.subkt.tasks / SubProperties

SubProperties

class SubProperties (source)

Reads a list of properties of the form release.entry.property=value, which can later be looked up using the match method.

Properties may contain wildcards, which will match any sequence of characters. For instance, a property defined as TV.episode*.name=value will be found with a match("name", entry="episode01", release="TV") call. Groups (e.g. {01,03,04}.op=OP1.ass) and ranges (e.g. {01..12}.cour=1) are also supported.

Unspecified release and entry components are equivalent to wildcards. In other words, name=value is equivalent to *.*.name=value, while 01.name=value is equivalent to *.01.name=value.

Properties are ordered, and the value of the last property matching the match query will be returned. Thus, later values will override earlier values.

Lines starting with # will be interpreted as comments and ignored.

Constructors

Name Summary
<init> SubProperties()
Reads a list of properties of the form release.entry.property=value, which can later be looked up using the match method.

Functions

Name Summary
add fun add(name: String, entry: String? = null, value: String): Unit
Add or override existing properties from the build script.
match fun match(property: String, entry: String= "", release:String= ""):String?
Finds the last property entry that matches the given property, entry and release.
parse fun parse(f: File): Unit