This file contains hidden or 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
using System; | |
using System.IO; | |
using System.Threading; | |
using Google.Apis.Auth.OAuth2; | |
using Google.Apis.Drive.v3; | |
using Google.Apis.Drive.v3.Data; | |
using Google.Apis.Requests; | |
using Google.Apis.Services; | |
using Google.Apis.Util.Store; |
This file contains hidden or 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
using Google.Apis.Drive.v3; | |
using Google.Apis.Drive.v3.Data; | |
using System; | |
using Google.Apis.Requests; | |
namespace GoogleApiSample.Drivev3 | |
{ | |
public static class AboutExamples | |
{ |
This file contains hidden or 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
using System; | |
using System.IO; | |
using System.Linq; | |
namespace FileScanner | |
{ | |
public class Program | |
{ | |
private const string _locationOfRepoToScan = @"C:\Development\IdentiyServer\IdentityServer4\src\IdentityServer4"; | |
private const string _localDirectoryReplace = @"C:\Development\IdentiyServer\IdentityServer4\"; |
This file contains hidden or 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
-- Instructions: | |
-- Run this in anohter window | |
-- SELECT CONVERT(varchar(255), NEWID()); | |
-- Enter values for new client | |
DECLARE @clientIdGuid AS VARCHAR(100) = '386B5AA0-2045-43B5-8DFE-ECF474F0A3D6'; | |
DECLARE @NEWCLIENTNAME AS VARCHAR(100) = 'Linda Test Client' | |
Declare @NEW_CLIENT_DESCRIPTION AS VARCHAR(100) = 'Linda Test CLient' | |
DECLARE @EMAIL_OF_OWNER AS VARCHAR(100) = '[email protected]'; | |
DECLARE @RedirectUri AS VARCHAR(100) = 'https://daimto.com'; |
This file contains hidden or 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
using Microsoft.Extensions.Configuration; | |
using Microsoft.Extensions.DependencyInjection; | |
using Microsoft.Extensions.Logging; | |
using System; | |
using System.IO; | |
namespace Daimto.DotnetCore.ConfigFiles | |
{ | |
class Program | |
{ |
This file contains hidden or 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
For service account auth include: | |
require_once __DIR__ . '/ServiceAccount.php'; | |
For Oauth2 include: | |
require_once __DIR__ . '/Oauth2Authentication.php'; | |
Note: To reset the auth for oauth to just unset the sessions |
This file contains hidden or 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
/** | |
* Created by Linda Lawton on 6/29/2017. | |
*/ | |
public class MergeSort { | |
public static void main(String[] args) throws Exception { | |
int[] data = new int[]{8, 3, 1, 7, 0}; | |
System.out.print("Before Sort: "); | |
for (int i = 0; i < data.length; i++) System.out.print( data[i] + ","); |
This file contains hidden or 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
import com.google.api.client.extensions.java6.auth.oauth2.AuthorizationCodeInstalledApp; | |
import com.google.api.client.extensions.jetty.auth.oauth2.LocalServerReceiver; | |
import com.google.api.client.auth.oauth2.Credential; | |
import com.google.api.client.googleapis.auth.oauth2.GoogleAuthorizationCodeFlow; | |
import com.google.api.client.googleapis.auth.oauth2.GoogleClientSecrets; | |
import com.google.api.client.googleapis.javanet.GoogleNetHttpTransport; | |
import com.google.api.client.http.HttpTransport; | |
import com.google.api.client.json.JsonFactory; | |
import com.google.api.client.json.jackson2.JacksonFactory; | |
import com.google.api.client.util.store.DataStoreFactory; |
This file contains hidden or 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
using Google.Apis.Json; | |
using Google.Apis.Util.Store; | |
using System; | |
using System.Data.Common; | |
using System.Threading.Tasks; | |
namespace GoogleAuthDataStores | |
{ | |
/// <summary> | |
/// Database data store that implements <see cref="IDataStore"/>. This store creates a different row for each |
This file contains hidden or 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
using System; | |
namespace GoogleDevTest | |
{ | |
class Program | |
{ | |
static void Main(string[] args) | |
{ | |
// 10 requests within 1 second | |
var que = new GoogleDevTest.GoogleFloodBuster(new TimeSpan(0, 0, 1), 10); |