-
Notifications
You must be signed in to change notification settings - Fork 14
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #65 from TheRealAgentK/master
4.0.1
- Loading branch information
Showing
15 changed files
with
143 additions
and
56 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,4 @@ | ||
package com.raygun.raygun4android.sample | ||
package com.raygun.raygun4androidsample.sample | ||
|
||
import android.app.Application | ||
import android.support.v7.app.AppCompatActivity | ||
|
@@ -22,9 +22,12 @@ class MainActivity : AppCompatActivity() { | |
RaygunClient.init(applicationContext as Application) | ||
RaygunClient.enableCrashReporting() | ||
RaygunClient.enableRUM(this) | ||
RaygunClient.shouldProcessBreadcrumbLocation(true) | ||
|
||
RaygunClient.setCustomData(initialCustomData) | ||
|
||
RaygunClient.setOnBeforeSend(SampleOnBeforeSend()) | ||
|
||
val buttonSend = findViewById<Button>(R.id.button_send) | ||
val buttonCrash = findViewById<Button>(R.id.button_crash) | ||
val buttonHandleException = findViewById<Button>(R.id.button_handleException) | ||
|
@@ -71,6 +74,7 @@ class MainActivity : AppCompatActivity() { | |
user.firstName = "User C" | ||
user.email = "[email protected]" | ||
RaygunClient.setUser(user) | ||
RaygunClient.recordBreadcrumb("I'm now user C") | ||
} | ||
|
||
buttonSetUserB.setOnClickListener{ | ||
|
@@ -79,6 +83,7 @@ class MainActivity : AppCompatActivity() { | |
user.firstName = "User D" | ||
user.email = "[email protected]" | ||
RaygunClient.setUser(user) | ||
RaygunClient.recordBreadcrumb("I'm now user D") | ||
} | ||
|
||
buttonSecondActivity.setOnClickListener { | ||
|
@@ -88,5 +93,8 @@ class MainActivity : AppCompatActivity() { | |
|
||
textViewAppVersion.text = "App ${BuildConfig.VERSION_NAME} (${BuildConfig.VERSION_CODE} ${BuildConfig.BUILD_TYPE})" | ||
textViewProviderVersion.text = "Provider ${com.raygun.raygun4android.BuildConfig.VERSION_NAME} (${com.raygun.raygun4android.BuildConfig.VERSION_CODE} ${BuildConfig.BUILD_TYPE})" | ||
|
||
RaygunClient.recordBreadcrumb("I'm here in Main Activity") | ||
|
||
} | ||
} |
12 changes: 12 additions & 0 deletions
12
app/src/main/java/com/raygun/raygun4androidsample/sample/SampleOnBeforeSend.kt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
package com.raygun.raygun4androidsample.sample | ||
|
||
import android.util.Log | ||
import com.raygun.raygun4android.CrashReportingOnBeforeSend | ||
import com.raygun.raygun4android.messages.crashreporting.RaygunMessage | ||
|
||
internal class SampleOnBeforeSend : CrashReportingOnBeforeSend { | ||
override fun onBeforeSend(message: RaygunMessage): RaygunMessage { | ||
Log.i("Raygun4Android-Sample", "In SampleOnBeforeSend - About to post to Raygun, returning the payload as is...") | ||
return message | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
2 changes: 1 addition & 1 deletion
2
.../raygun4android/sample/ExampleUnitTest.kt → ...n4androidsample/sample/ExampleUnitTest.kt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,4 @@ | ||
package com.raygun.raygun4android.sample | ||
package com.raygun.raygun4androidsample.sample | ||
|
||
import org.junit.Test | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters