package Ġio . op entelemetry . kotlin . api . common Ċ Ċ import Ġkotlinx . datetime . DateTime Unit Ċ Ċ fun ĠDateTime Unit . get Nan os (): ĠLong Ġ{ ĊĠĠĠ Ġreturn Ġwhen Ġ( this ) Ġ{ ĊĠĠĠĠĠĠĠ Ġis ĠDateTime Unit . Time Based Ġ-> Ġnan oseconds ĊĠĠĠĠĠĠĠ Ġis ĠDateTime Unit . Day Based Ġ-> ĠDateTime Unit . HOUR . nan oseconds Ġ* Ġ 2 4 Ġ* Ġdays ĊĠĠĠĠĠĠĠ Ġis ĠDateTime Unit . Month Based Ġ-> ĊĠĠĠĠĠĠĠĠĠĠĠ Ġthrow ĠIllegalStateException (" Month Ġbased ĠDateTime Units Ġcan Ġnot Ġbe Ġconverted Ġto Ġnan os ") ĊĠĠĠ Ġ} Ċ } Ċ Ċ fun ĠDateTime Unit . normalize To Nan os ( timestamp : ĠLong ): ĠLong Ġ{ ĊĠĠĠ Ġreturn Ġthis . get Nan os () Ġ* Ġtimestamp Ċ } Ċ Ċ fun ĠDateTime Unit . normalize To Nan os ( timestamp : ĠInt ): ĠLong Ġ{ ĊĠĠĠ Ġreturn Ġthis . get Nan os () Ġ* Ġtimestamp Ċ } Ċ Ċ fun ĠDateTime Unit . normalize To Milliseconds ( timestamp : ĠInt ): ĠLong Ġ{ ĊĠĠĠ Ġreturn Ġnormalize To Nan os ( timestamp ) Ġ/ Ġ 1 0 0 0 Ċ } Ċ Ċ fun ĠDateTime Unit . normalize To Milliseconds ( timestamp : ĠLong ): ĠLong Ġ{ ĊĠĠĠ Ġreturn Ġnormalize To Nan os ( timestamp ) Ġ/ Ġ 1 0 0 0 Ċ } Ċ