Get explore categories
https://api-v2.soundcloud.com/explore/categories?limit=10&offset=0&linked_partitioning=1&client_id=ID_HERE
Example
import javax.net.ssl.HttpsURLConnection; | |
import java.awt.Color; | |
import java.io.IOException; | |
import java.io.OutputStream; | |
import java.lang.reflect.Array; | |
import java.net.URL; | |
import java.util.ArrayList; | |
import java.util.HashMap; | |
import java.util.List; | |
import java.util.Map; |
/* | |
##Device = Desktops | |
##Screen = 1281px to higher resolution desktops | |
*/ | |
@media (min-width: 1281px) { | |
/* CSS */ | |
<!DOCTYPE html> | |
<html> | |
<head> | |
<meta charset="UTF-8"> | |
<title>A simple clock</title> | |
</head> | |
<body translate="no" > |
//Authorization | |
{ ApiCommand.AuthorizationCodeFlow, new Uri("https://soundcloud.com/connect?scope=non-expiring&client_id={0}&response_type={1}&redirect_uri={2}") }, | |
{ ApiCommand.UserAgentFlow, new Uri("https://soundcloud.com/connect?client_id={0}&response_type=token&redirect_uri={1}") }, | |
{ ApiCommand.UserCredentialsFlow, new Uri("https://api.soundcloud.com/oauth2/token?client_id={0}&client_secret={1}&grant_type=password&username={2}&password={3}") }, | |
{ ApiCommand.RefreshToken, new Uri("https://api.soundcloud.com/oauth2/token?client_id={0}&client_secret={1}&grant_type=refresh_token&refresh_token={2}") }, | |
//Me | |
{ ApiCommand.Me, new Uri("https://api.soundcloud.com/me.json") }, | |
{ ApiCommand.MeTracks, new Uri("https://api.soundcloud.com/me/tracks.json") }, | |
{ ApiCommand.MeComments, new Uri("https://api.soundcloud.com/me/comments.json") }, |
$('body').on('click', '#messages-view a', (event) => { | |
event.preventDefault(); | |
let link = event.target.href; | |
require("electron").shell.openExternal(link); | |
}); |
/* | |
* The MIT License | |
* Copyright (c) 2015 Techcable | |
* | |
* Permission is hereby granted, free of charge, to any person obtaining a copy | |
* of this software and associated documentation files (the "Software"), to deal | |
* in the Software without restriction, including without limitation the rights | |
* to use, copy, modify, merge, publish, distribute, sublicense, and/or sell | |
* copies of the Software, and to permit persons to whom the Software is | |
* furnished to do so, subject to the following conditions: |
// java.util.List の初期化を一行で書く | |
List<String> list = new ArrayList<String>() {{add("a"); add("b"); add("c");}}; | |
// 変更不可能な List で良い場合は | |
List list = Arrays.asList("a", "b", "c"); | |
// Arrays.asList をジェネリックスを使って書くと | |
List<Integer> list = Arrays.<Integer>asList(1, 2, 3); | |
// asList を使いつつ、追加可能な List を作るには、冗長だが以下のようにする | |
List<Integer> list = new ArrayList<Integer>(Arrays.<Integer>asList(1, 2, 3)); |
//META{"name":"ConnectionTime","website":"https://kataba.me/","source":"https://gist.github.com/katabame/ef65c6379c8d50af8702c5932c6dbf5b"}*// | |
/* | |
MIT License | |
Copyright (c) 2018 katabame | |
Permission is hereby granted, free of charge, to any person obtaining a copy | |
of this software and associated documentation files (the "Software"), to deal | |
in the Software without restriction, including without limitation the rights |