package Ġex po . modules . med iali brary Ċ Ċ import Ġandroid . provider . Media Store Ċ Ċ enum Ġclass ĠMediaType ( val Ġapi Name : ĠString , Ġval Ġmedia Column : ĠInt ?) Ġ{ ĊĠ ĠA UDIO (" audio ", ĠMedia Store . Files . File Columns . MEDIA _ TYPE _ AUDIO ), ĊĠ ĠPH OTO (" photo ", ĠMedia Store . Files . File Columns . MEDIA _ TYPE _ IMAGE ), ĊĠ ĠV IDE O (" video ", ĠMedia Store . Files . File Columns . MEDIA _ TYPE _ VIDEO ), ĊĠ ĠUNKNOWN (" unknown ", ĠMedia Store . Files . File Columns . MEDIA _ TYPE _ NONE ), ĊĠ ĠALL (" all ", Ġnull ); ĊĊĠ Ġcompanion Ġobject Ġ{ ĊĠĠĠ Ġ// Ġall Ġconstants Ġhave Ġkeys Ġequal Ġto Ġthe Ġvalues ĊĠĠĠ Ġfun Ġget Constants () Ġ= Ġvalues (). map Ġ{ ĠPair ( it . api Name , Ġit . api Name ) Ġ}. toMap () ĊĊĠĠĠ Ġfun Ġfrom Api Name ( constant Name : ĠString ) Ġ= Ġvalues (). find Ġ{ Ġit . api Name Ġ== Ġconstant Name Ġ} ĊĠ Ġ} Ċ } Ċ Ċ enum Ġclass ĠSort By ( val Ġkey Name : ĠString , Ġval Ġmedia ColumnName : ĠString ) Ġ{ ĊĠ ĠDEFAULT (" default ", ĠMedia Store . Images . Media ._ ID ), ĊĠ ĠCRE ATION _ TIME (" creation Time ", ĠMedia Store . Images . Media . DATE _ TA KEN ), ĊĠ ĠMO DIF ICATION _ TIME (" modification Time ", ĠMedia Store . Images . Media . DATE _ MODI FIED ), ĊĠ ĠMED IA _ TYPE (" media Type ", ĠMedia Store . Files . File Columns . MEDIA _ TYPE ), ĊĠ ĠWIDTH (" width ", ĠMedia Store . Media Columns . WIDTH ), ĊĠ ĠHEIGHT (" height ", ĠMedia Store . Media Columns . HEIGHT ), ĊĠ ĠD URATION (" duration ", ĠMedia Store . Video . Video Columns . DURATION ); ĊĊĠ Ġcompanion Ġobject Ġ{ ĊĠĠĠ Ġ// Ġall Ġconstants Ġhave Ġkeys Ġequal Ġto Ġthe Ġvalues ĊĠĠĠ Ġfun Ġget Constants () Ġ= Ġvalues (). map Ġ{ ĠPair ( it . key Name , Ġit . key Name ) Ġ}. toMap () ĊĊĠĠĠ Ġfun Ġfrom KeyName ( key Name : ĠString ) Ġ= Ġvalues (). find Ġ{ Ġit . key Name Ġ== Ġkey Name Ġ} ĊĠ Ġ} Ċ } Ċ