package Ġcom . shake bugs . demo Ċ Ċ import Ġandroid . app . Application Ċ import Ġcom . shake bugs . demo . Build Config Ċ import Ġcom . shake bugs . demo . utils . Preference Utils Ċ import Ġcom . shake bugs . shake . Sh ake Ċ import Ġjava . util .* Ċ Ċ class ĠSh ake Demo App Ġ: ĠApplication () Ġ{ ĊĊĠĠĠ Ġoverride Ġfun ĠonCreate () Ġ{ ĊĠĠĠĠĠĠĠ Ġsuper . onCreate () ĊĊĠĠĠĠĠĠĠ Ġval Ġpreference Utils Ġ= ĠPreference Utils () ĊĊĠĠĠĠĠĠĠ Ġif Ġ( preference Utils . getString ( this , ĠPreference Utils . PRE F _ APP _ UUID ). equals ("")) Ġ{ ĊĠĠĠĠĠĠĠĠĠĠĠ Ġpreference Utils . save String ( this , ĠPreference Utils . PRE F _ APP _ UUID , ĠUUID . randomUUID (). toString ()) ĊĊĠĠĠĠĠĠĠĠĠĠĠ Ġpreference Utils . save Boolean ( this , ĠPreference Utils . IS _ INV OK ED _ BY _ SH AK ING , Ġtrue ) ĊĠĠĠĠĠĠĠĠĠĠĠ Ġpreference Utils . save Int ( this , ĠPreference Utils . SH AK ING _ THRESHOLD , ĠSh ake . get Report Configuration (). sh aking Threshold ) ĊĠĠĠĠĠĠĠĠĠĠĠ Ġpreference Utils . save Boolean ( this , ĠPreference Utils . IS _ FLOAT ING _ BUTTON _ SHO WN , Ġfalse ) ĊĠĠĠĠĠĠĠĠĠĠĠ Ġpreference Utils . save Boolean ( this , ĠPreference Utils . IS _ INV OK ED _ ON _ SCREEN SHOT , Ġfalse ) ĊĠĠĠĠĠĠĠĠĠĠĠ Ġpreference Utils . save Boolean ( this , ĠPreference Utils . IS _ INV OK ED _ ON _ RIGHT _ EDGE _ PAN , Ġfalse ) ĊĊĠĠĠĠĠĠĠĠĠĠĠ Ġpreference Utils . save Boolean ( this , ĠPreference Utils . IS _ CONSOLE _ LOG _ ENABLED , Ġfalse ) ĊĠĠĠĠĠĠĠĠĠĠĠ Ġpreference Utils . save Boolean ( this , ĠPreference Utils . IS _ BLACK BOX _ ENABLED , Ġtrue ) ĊĊĠĠĠĠĠĠĠĠĠĠĠ Ġpreference Utils . save Boolean ( this , ĠPreference Utils . IS _ SCREEN SHOT _ INCLUDED , Ġtrue ) ĊĠĠĠĠĠĠĠĠĠĠĠ Ġpreference Utils . save Boolean ( this , ĠPreference Utils . IS _ EMAIL _ FIELD _ ENABLED , Ġfalse ) ĊĠĠĠĠĠĠĠĠĠĠĠ Ġpreference Utils . save Boolean ( this , ĠPreference Utils . IS _ INS PECT _ SCREEN _ ENABLED , Ġfalse ) ĊĠĠĠĠĠĠĠĠĠĠĠ Ġpreference Utils . save Boolean ( this , ĠPreference Utils . IS _ FEED BACK _ TYPE _ ENABLED , Ġfalse ) ĊĊĠĠĠĠĠĠĠ Ġ} ĊĊĠĠĠĠĠĠĠ ĠSh ake . set Crash Reporting Enabled ( true ) ĊĠĠĠĠĠĠĠ ĠSh ake . set Ask For Crash Description ( true ) ĊĊĠĠĠĠĠĠĠ ĠSh ake . get Report Configuration (). is Invoke Sh ake On Sh ake Device Event Ġ= Ġpreference Utils . getBoolean ( this , ĠPreference Utils . IS _ INV OK ED _ BY _ SH AK ING ) ĊĠĠĠĠĠĠĠ ĠSh ake . get Report Configuration (). sh aking Threshold Ġ= Ġpreference Utils . getInt ( this , ĠPreference Utils . SH AK ING _ THRESHOLD ) ĊĠĠĠĠĠĠĠ ĠSh ake . get Report Configuration (). is Show Floating Report Button Ġ= Ġpreference Utils . getBoolean ( this , ĠPreference Utils . IS _ FLOAT ING _ BUTTON _ SHO WN ) ĊĠĠĠĠĠĠĠ ĠSh ake . get Report Configuration (). is Invoke Sh ake On Screenshot Ġ= Ġpreference Utils . getBoolean ( this , ĠPreference Utils . IS _ INV OK ED _ ON _ SCREEN SHOT ) ĊĠĠĠĠĠĠĠ ĠSh ake . get Report Configuration (). is Invoke Sh ake On Right Edge Pan Ġ= Ġpreference Utils . getBoolean ( this , ĠPreference Utils . IS _ INV OK ED _ ON _ RIGHT _ EDGE _ PAN ) ĊĊĠĠĠĠĠĠĠ ĠSh ake . get Report Configuration (). is Console Logs Enabled Ġ= Ġpreference Utils . getBoolean ( this , ĠPreference Utils . IS _ CONSOLE _ LOG _ ENABLED ) ĊĠĠĠĠĠĠĠ ĠSh ake . get Report Configuration (). is Enable Black Box Ġ= Ġpreference Utils . getBoolean ( this , ĠPreference Utils . IS _ BLACK BOX _ ENABLED ) ĊĊĠĠĠĠĠĠĠ ĠSh ake . get Report Configuration (). is Auto Video Recording Ġ= Ġfalse ĊĠĠĠĠĠĠĠ ĠSh ake . get Report Configuration (). is Screenshot Included Ġ= Ġpreference Utils . getBoolean ( this , ĠPreference Utils . IS _ SCREEN SHOT _ INCLUDED ) ĊĊĠĠĠĠĠĠĠ ĠSh ake . get Report Configuration (). is Enable Email Field Ġ= Ġpreference Utils . getBoolean ( this , ĠPreference Utils . IS _ EMAIL _ FIELD _ ENABLED ) ĊĠĠĠĠĠĠĠ ĠSh ake . get Report Configuration (). is Enable Inspect Screen Ġ= Ġpreference Utils . getBoolean ( this , ĠPreference Utils . IS _ INS PECT _ SCREEN _ ENABLED ) ĊĠĠĠĠĠĠĠ ĠSh ake . get Report Configuration (). is Feedback Type Enabled Ġ= Ġpreference Utils . getBoolean ( this , ĠPreference Utils . IS _ FEED BACK _ TYPE _ ENABLED ) ĊĠĠĠĠĠĠĠ ĠSh ake . set Show Intro Message ( true ) ĊĊĠĠĠĠĠĠĠ ĠSh ake . start ( this , ĠBuild Config . CLIENT _ ID , ĠBuild Config . CLIENT _ SECRET ) ĊĊĠĠĠĠĠĠĠ ĠSh ake . register User ( preference Utils . getString ( this , ĠPreference Utils . PRE F _ APP _ UUID )) ĊĠĠĠĠĠĠĠ ĠSh ake . update User Metadata ( map Of ( ĊĠĠĠĠĠĠĠĠĠĠĠ Ġ" first _ name " Ġto Ġ" John ", ĊĠĠĠĠĠĠĠĠĠĠĠ Ġ" last _ name " Ġto Ġ" Do e ", ĊĠĠĠĠĠĠĠĠĠĠĠ Ġ" email " Ġto Ġ" john . doe @ email . com ", ĊĠĠĠĠĠĠĠĠĠĠĠ Ġ" status " Ġto Ġ" Active ", ĊĠĠĠĠĠĠĠĠĠĠĠ Ġ" cart Items " Ġto Ġ" 3 ", ĊĠĠĠĠĠĠĠĠĠĠĠ Ġ" cart Total " Ġto Ġ"$ 2 5 . 3 3 " ĊĠĠĠĠĠĠĠ Ġ)) ĊĊĠĠĠ Ġ} Ċ }