Pastebin API Klasse

    • VB.NET

    Es gibt 1 Antwort in diesem Thema. Der letzte Beitrag () ist von J.Herbrich.

      Pastebin API Klasse

      Da ich solch eine Klasse gerade für ein Projekt benötige, habe ich mir kurzerhand eine gemacht.

      Ihr benötigt nur einen APIKey, welchen ihr hier bekommen könnt : pastebin.com/api#1

      Diesen müsst ihr der Property "dev_key" zuweisen.

      Anbei habe ich ein Testprojekt angehängt, um auf die genauen Funktionen einzugehen, dieses ist ziemlich primitiv und einfach gehalten. Ich bitte euch, euch nicht an dem Beispiel festzuhalten oder gar den Code kopieren. Es ist nur da um euch die Funktionen zu zeigen.


      Hier die Klasse:

      Quellcode

      1. Option Strict On
      2. Option Explicit On
      3. Imports System.Net
      4. Imports System.Text.RegularExpressions
      5. Imports System.Xml
      6. Imports System.IO
      7. Imports System.Text
      8. Imports System.Net.NetworkInformation
      9. Public Class Pastebin
      10. #Region "POST req function"
      11. Private Shared cookie As New CookieContainer
      12. Public Shared Function Postreq(ByVal Url As String, ByVal post As String) As String
      13. Dim request As HttpWebRequest
      14. request = CType(HttpWebRequest.Create(Url), HttpWebRequest)
      15. request.Method = WebRequestMethods.Http.Post
      16. request.CookieContainer = cookie
      17. request.UserAgent = "Mozilla/5.0 (Windows NT 6.3; WOW64; rv:29.0) Gecko/20100101 Firefox/29.0"
      18. request.ContentType = "application/x-www-form-urlencoded"
      19. Dim byteArr() As Byte = Encoding.Default.GetBytes(post)
      20. request.ContentLength = byteArr.Length
      21. Dim dataStream As Stream = request.GetRequestStream()
      22. dataStream.Write(byteArr, 0, byteArr.Length)
      23. Dim response As HttpWebResponse
      24. response = CType(request.GetResponse(), HttpWebResponse)
      25. Return New StreamReader(response.GetResponseStream()).ReadToEnd()
      26. End Function
      27. #End Region
      28. Private Shared Property dev_key As String = "" 'Your dev-key
      29. Public Shared Property Username As String 'Property "Username" - must be setted first
      30. Public Shared Property Password As String 'Property "Password" - must be setted first
      31. ''' <summary>
      32. ''' Returns the UserAPIKey, also know as session key
      33. ''' </summary>
      34. ''' <returns></returns>
      35. ''' <remarks></remarks>
      36. Public Shared Function GetUserAPIKey() As String
      37. If String.IsNullOrEmpty(Username) OrElse String.IsNullOrEmpty(Password) Then
      38. Return "False"
      39. Exit Function
      40. End If
      41. Dim post As String = "api_dev_key=" & dev_key & "&api_user_name=" & Username & "&api_user_password=" & Password
      42. Dim url As String = "http://pastebin.com/api/api_login.php"
      43. Dim UserAPIKey As String = CStr(Postreq(url, post))
      44. Return UserAPIKey
      45. End Function
      46. Public Structure UserInformations
      47. Dim Username As String
      48. Dim UserFormat As String
      49. Dim UserExpiration As String
      50. Dim AvatarUrl As Uri
      51. Dim UserPrivate As String
      52. Dim UserEmail As String
      53. Dim UserWebsite As Uri
      54. Dim UserLocation As String
      55. Dim UserIsPro As Boolean
      56. End Structure
      57. ''' <summary>
      58. ''' Function to get Userinformations
      59. ''' </summary>
      60. ''' <returns>Specific Userinformations</returns>
      61. ''' <remarks></remarks>
      62. Public Shared Function GetUserInformations() As UserInformations
      63. Dim Info As New UserInformations
      64. Dim UserAPIKey As String = GetUserAPIKey()
      65. Dim post As String = "api_option=userdetails&api_user_key=" & UserAPIKey & "&api_dev_key=" & dev_key
      66. Dim Url As String = "http://pastebin.com/api/api_post.php"
      67. Dim html As String = CStr(Postreq(Url, post))
      68. Using reader As XmlReader = XmlReader.Create(New StringReader(html))
      69. With New StringBuilder
      70. reader.ReadToFollowing("user_name")
      71. reader.MoveToFirstAttribute()
      72. Info.Username = reader.ReadElementContentAsString()
      73. reader.ReadToFollowing("user_format_short")
      74. Info.UserFormat = reader.ReadElementContentAsString()
      75. reader.ReadToFollowing("user_expiration")
      76. Dim exp As String = reader.ReadElementContentAsString()
      77. Select Case exp
      78. Case CStr(exp = "N")
      79. exp = "Never"
      80. Info.UserExpiration = exp
      81. Case Else
      82. Info.UserExpiration = exp
      83. End Select
      84. ' Info.UserExpiration = exp
      85. reader.ReadToFollowing("user_avatar_url")
      86. Info.AvatarUrl = New Uri(reader.ReadElementContentAsString)
      87. reader.ReadToFollowing("user_private")
      88. Dim private_ As String = reader.ReadElementContentAsString
      89. Select Case private_
      90. Case "0"
      91. private_ = "Public"
      92. Info.UserPrivate = private_
      93. Case "1"
      94. private_ = "Unlisted"
      95. Info.UserPrivate = private_
      96. Case "2"
      97. private_ = "Private"
      98. Info.UserPrivate = private_
      99. End Select
      100. reader.ReadToFollowing("user_website")
      101. Dim Website_s As String = reader.ReadElementContentAsString
      102. If Not String.IsNullOrEmpty(Website_s) Then
      103. Dim Website As Uri = New Uri(reader.ReadElementContentAsString)
      104. Info.UserWebsite = Website
      105. End If
      106. reader.ReadToFollowing("user_email")
      107. Info.UserEmail = reader.ReadElementContentAsString
      108. reader.ReadToFollowing("user_location")
      109. Info.UserLocation = reader.ReadElementContentAsString
      110. reader.ReadToFollowing("user_account_type")
      111. Dim UserIsPro_s As String = reader.ReadElementContentAsString
      112. Dim UserIsPro As Boolean
      113. Select Case UserIsPro_s
      114. Case "0"
      115. UserIsPro = False
      116. Case "1"
      117. UserIsPro = True
      118. End Select
      119. Info.UserIsPro = UserIsPro
      120. End With
      121. End Using
      122. Return Info
      123. End Function
      124. Public Enum syntax
      125. sixfivenulltwoacme = 0
      126. sixfivenulltwokickass = 1
      127. sixfivenulltwotasm = 2
      128. abap = 3
      129. actionscript = 4
      130. actionscript3 = 5
      131. ada = 6
      132. algol68 = 7
      133. apache = 8
      134. applescript = 9
      135. apt_sources = 10
      136. arm = 11
      137. asm = 12
      138. asp = 13
      139. asymptote = 14
      140. autoconf = 15
      141. autohotkey = 16
      142. autoit = 17
      143. avisynth = 18
      144. awk = 19
      145. bascomavr = 20
      146. bash = 21
      147. basic4gl = 22
      148. bibtex = 23
      149. blitzbasic = 24
      150. bnf = 25
      151. boo = 26
      152. bf = 27
      153. c = 28
      154. c_mac = 29
      155. cil = 30
      156. csharp = 31
      157. cpp = 32
      158. cpp_qt = 33
      159. c_loadrunner = 34
      160. caddcl = 35
      161. cadlisp = 36
      162. cfdg = 37
      163. chaiscript = 38
      164. clojure = 39
      165. klonec = 40
      166. klonecpp = 41
      167. cmake = 42
      168. cobol = 43
      169. coffeescript = 44
      170. cfm = 45
      171. css = 46
      172. cuesheet = 47
      173. d = 48
      174. dcl = 49
      175. dcpu16 = 50
      176. dcs = 51
      177. delphi = 52
      178. oxygene = 53
      179. diff = 54
      180. div = 55
      181. dos = 56
      182. dot = 57
      183. e = 58
      184. ecmascript = 59
      185. eiffel = 60
      186. email = 61
      187. epc = 62
      188. erlang = 63
      189. fsharp = 64
      190. falcon = 65
      191. fo = 66
      192. f1 = 67
      193. fortran = 68
      194. freebasic = 69
      195. freeswitch = 70
      196. gambas = 71
      197. gml = 72
      198. gdb = 73
      199. genero = 74
      200. genie = 75
      201. gettext = 76
      202. go = 77
      203. groovy = 78
      204. gwbasic = 79
      205. haskell = 80
      206. haxe = 81
      207. hicest = 82
      208. hq9plus = 83
      209. html4strict = 84
      210. html5 = 85
      211. icon = 86
      212. idl = 87
      213. ini = 88
      214. inno = 89
      215. intercal = 90
      216. io = 91
      217. j = 92
      218. java = 93
      219. java5 = 94
      220. javascript = 95
      221. jquery = 96
      222. kixtart = 97
      223. latex = 98
      224. ldif = 99
      225. lb = 100
      226. lsl2 = 101
      227. lisp = 102
      228. llvm = 103
      229. locobasic = 104
      230. logtalk = 105
      231. lolcode = 106
      232. lotusformulas = 107
      233. lotusscript = 108
      234. lscript = 109
      235. lua = 110
      236. m68k = 111
      237. magiksf = 112
      238. make = 113
      239. mapbasic = 114
      240. matlab = 115
      241. mirc = 116
      242. mmix = 117
      243. modula2 = 118
      244. modula3 = 119
      245. mpasm = 121
      246. mxml = 122
      247. mysql = 123
      248. nagios = 124
      249. newlisp = 125
      250. text = 126
      251. nsis = 127
      252. oberon2 = 128
      253. objeck = 129
      254. objc = 130
      255. octave = 133
      256. pf = 134
      257. glsl = 135
      258. oobas = 136
      259. oracle11 = 137
      260. oracle8 = 138
      261. oz = 139
      262. parasail = 140
      263. parigp = 141
      264. pascal = 142
      265. pawn = 143
      266. pcre = 144
      267. per = 145
      268. perl = 146
      269. perl6 = 147
      270. php = 148
      271. php_brief = 149
      272. pic16 = 150
      273. pike = 151
      274. pixelbender = 152
      275. plsql = 153
      276. postgresql = 154
      277. povray = 155
      278. powershell = 156
      279. powerbuilder = 157
      280. proftpd = 158
      281. progress = 159
      282. prolog = 160
      283. properties = 161
      284. providex = 162
      285. purebasic = 163
      286. pycon = 164
      287. python = 165
      288. pys60 = 166
      289. q = 167
      290. qbasic = 168
      291. rsplus = 169
      292. rails = 170
      293. rebol = 171
      294. reg = 172
      295. rexx = 173
      296. robots = 174
      297. rpmspec = 175
      298. ruby = 176
      299. gnuplot = 177
      300. sas = 178
      301. scala = 179
      302. scheme = 180
      303. scilab = 181
      304. sdlbasic = 182
      305. smalltalk = 183
      306. smarty = 184
      307. spark = 185
      308. sparql = 186
      309. sql = 187
      310. stonescript = 188
      311. systemverilog = 189
      312. tsql = 190
      313. tcl = 191
      314. teraterm = 192
      315. thinbasic = 193
      316. typoscript = 194
      317. unicon = 195
      318. uscript = 196
      319. ups = 197
      320. urbi = 198
      321. vala = 199
      322. vbnet = 200
      323. vedit = 201
      324. verilog = 202
      325. vhdl = 203
      326. vim = 204
      327. visualprolog = 205
      328. vb = 206
      329. visualfoxpro = 207
      330. whitespace = 208
      331. whois = 209
      332. winbatch = 210
      333. xbasic = 211
      334. xml = 212
      335. xorg_conf = 213
      336. xpp = 214
      337. yaml = 215
      338. z80 = 216
      339. zxbasic = 217
      340. End Enum
      341. Private Shared Function getSyntax(ByVal s As syntax) As String
      342. Dim Syntax As String = s.ToString
      343. Select Case Syntax
      344. Case Is = "sixfivenulltwoacme"
      345. Syntax = "6502acme"
      346. Return Syntax
      347. Case Is = "sixfivenulltwokickass"
      348. Syntax = "6502kickass"
      349. Return Syntax
      350. Case Is = "sixfivenulltwotasm"
      351. Syntax = "6502tasm"
      352. Return Syntax
      353. Case Is = "cpp_qt"
      354. Syntax = "cpp-qt"
      355. Return Syntax
      356. Case Is = "php_brief"
      357. Syntax = "php-brief"
      358. Return Syntax
      359. Case Else
      360. Return Syntax
      361. End Select
      362. End Function
      363. Public Enum PasteExpire
      364. Never = 0
      365. ten_minutes = 1
      366. one_hour = 2
      367. one_day = 3
      368. one_week = 4
      369. two_weeks = 5
      370. one_month = 6
      371. End Enum
      372. Private Shared Function getPasteExpire(ByVal s As PasteExpire) As String
      373. Select Case s
      374. Case CType(s = PasteExpire.Never, PasteExpire)
      375. Return "N"
      376. Case CType(s = PasteExpire.one_day, PasteExpire)
      377. Return "1D"
      378. Case CType(s = PasteExpire.one_hour, PasteExpire)
      379. Return "1H"
      380. Case CType(s = PasteExpire.one_month, PasteExpire)
      381. Return "1M"
      382. Case CType(s = PasteExpire.one_week, PasteExpire)
      383. Return "1W"
      384. Case CType(s = PasteExpire.ten_minutes, PasteExpire)
      385. Return "10M"
      386. Case CType(s = PasteExpire.two_weeks, PasteExpire)
      387. Return "2W"
      388. Case Else
      389. Return Nothing
      390. End Select
      391. End Function
      392. Public Enum Privacy
      393. PublicPaste
      394. UnlistedPaste
      395. PrivatePaste
      396. End Enum
      397. Private Shared Function getPrivacy(ByVal s As Privacy) As String
      398. Select Case s.ToString
      399. Case "PrivatePaste"
      400. Return "2"
      401. Case "PublicPaste"
      402. Return "0"
      403. Case "UnlistedPaste"
      404. Return "1"
      405. Case Else
      406. End Select
      407. End Function
      408. ''' <summary>
      409. ''' Pastes a Text and returns the URL
      410. ''' </summary>
      411. ''' <param name="Title">Your title</param>
      412. ''' <param name="Text">Your text</param>
      413. ''' <param name="useLogin">UseLogin or Pasteanonymous</param>
      414. ''' <param name="syntax">The syntaxhighliting</param>
      415. ''' <param name="expire">The expiredate</param>
      416. ''' <param name="privacy">the privacy settings</param>
      417. ''' <returns></returns>
      418. ''' <remarks></remarks>
      419. Public Shared Function Paste(ByVal Title As String, ByVal Text As String, ByVal useLogin As Boolean, ByVal syntax As syntax, ByVal expire As PasteExpire, ByVal privacy As Privacy) As Uri
      420. Dim Syntax_ As String
      421. Dim Expire_ As String
      422. Dim Privacy_ As String
      423. Dim UserAPIKey As String = GetUserAPIKey()
      424. If useLogin = False AndAlso privacy = Pastebin.Privacy.PrivatePaste Then
      425. Return Nothing
      426. Exit Function
      427. End If
      428. Syntax_ = getSyntax(syntax)
      429. Expire_ = getPasteExpire(expire)
      430. Privacy_ = getPrivacy(privacy)
      431. If String.IsNullOrEmpty(Text) Then
      432. Return Nothing
      433. Exit Function
      434. End If
      435. Dim Post As String = "api_option=paste&api_user_key=" & UserAPIKey & "&api_paste_private=" & Privacy_ & "&api_paste_name=" & Title & "&api_paste_expire_date=" & Expire_ & "&papi_paste_format.=" & Syntax_ & "&api_dev_key=" & dev_key & "&api_paste_code=" & Text
      436. Dim URL As String = "http://pastebin.com/api/api_post.php"
      437. Dim ReturnLink As String = CStr(Postreq(URL, Post))
      438. Dim ReturnUri As Uri = New Uri(ReturnLink)
      439. If ReturnUri IsNot Nothing Then
      440. Return ReturnUri
      441. End If
      442. End Function
      443. ''' <summary>
      444. ''' The structure "pastes"
      445. ''' </summary>
      446. ''' <remarks></remarks>
      447. Public Structure Pastes
      448. Dim PasteKey As List(Of String)
      449. Dim PasteDate As List(Of Integer)
      450. Dim PasteTitle As List(Of String)
      451. Dim PasteSize As List(Of Integer)
      452. Dim PasteExpireDate As List(Of Integer)
      453. Dim PasteIsPrivate As List(Of Boolean)
      454. Dim PasteFormat As List(Of String)
      455. Dim PasteUrl As List(Of Uri)
      456. Dim PasteHits As List(Of Integer)
      457. End Structure
      458. ''' <summary>
      459. ''' Returns a List of your Pastes
      460. ''' </summary>
      461. ''' <returns>Specific List's</returns>
      462. ''' <remarks></remarks>
      463. Public Shared Function getUserPastes(ByVal Limit As Integer) As Pastes
      464. Dim PasteKey As New List(Of String)
      465. Dim PasteDate As New List(Of Integer)
      466. Dim PasteTitle As New List(Of String)
      467. Dim PasteSize As New List(Of Integer)
      468. Dim PasteExpireDate As New List(Of Integer)
      469. Dim PasteIsPrivate As New List(Of Boolean)
      470. Dim PasteFormat As New List(Of String)
      471. Dim PasteUrl As New List(Of Uri)
      472. Dim PasteHits As New List(Of Integer)
      473. Dim UserAPIKey As String = GetUserAPIKey()
      474. Dim post As String = "api_option=list&api_user_key=" & UserAPIKey & "&api_dev_key=" & dev_key & "&api_results_limit=" & Limit.ToString
      475. Dim html As String = Postreq("http://pastebin.com/api/api_post.php", post)
      476. For Each m As Match In New Regex("<paste_key>(.+)</paste_key>").Matches(html)
      477. PasteKey.Add(m.Groups.Item(1).Value)
      478. Next
      479. For Each m As Match In New Regex("<paste_date>(.+)</paste_date>").Matches(html)
      480. PasteDate.Add(Integer.Parse(m.Groups.Item(1).Value))
      481. Next
      482. For Each m As Match In New Regex("<paste_title>(.+)</paste_title>").Matches(html)
      483. PasteTitle.Add(m.Groups.Item(1).Value)
      484. Next
      485. For Each m As Match In New Regex("<paste_size>(.+)</paste_size>").Matches(html)
      486. PasteSize.Add(Integer.Parse(m.Groups.Item(1).Value))
      487. Next
      488. For Each m As Match In New Regex("<paste_expire_date>(.+)</paste_expire_date>").Matches(html)
      489. PasteExpireDate.Add(Integer.Parse(m.Groups.Item(1).Value))
      490. Next
      491. For Each m As Match In New Regex("<paste_private>(.+)</paste_private>").Matches(html)
      492. If m.Groups.Item(1).Value = "0" Then
      493. PasteIsPrivate.Add(False)
      494. Else
      495. PasteIsPrivate.Add(True)
      496. End If
      497. Next
      498. For Each m As Match In New Regex("<paste_format_long>(.+)</paste_format_long>").Matches(html)
      499. PasteFormat.Add(m.Groups.Item(1).Value)
      500. Next
      501. For Each m As Match In New Regex("<paste_url>(.+)</paste_url>").Matches(html)
      502. PasteUrl.Add(New Uri(m.Groups.Item(1).Value))
      503. Next
      504. For Each m As Match In New Regex("<paste_hits>(.+)</paste_hits>").Matches(html)
      505. PasteHits.Add(Integer.Parse(m.Groups.Item(1).Value))
      506. Next
      507. Dim Paste As New Pastes
      508. Paste.PasteDate = PasteDate
      509. Paste.PasteExpireDate = PasteExpireDate
      510. Paste.PasteFormat = PasteFormat
      511. Paste.PasteHits = PasteHits
      512. Paste.PasteIsPrivate = PasteIsPrivate
      513. Paste.PasteKey = PasteKey
      514. Paste.PasteSize = PasteSize
      515. Paste.PasteTitle = PasteTitle
      516. Paste.PasteUrl = PasteUrl
      517. Return Paste
      518. End Function
      519. ''' <summary>
      520. ''' Returns a List of Trending Pastes
      521. ''' </summary>
      522. ''' <returns>Specific List's</returns>
      523. ''' <remarks></remarks>
      524. Public Shared Function getTrandingPastes() As Pastes
      525. Dim post As String = "api_option=trends&api_dev_key=" & dev_key
      526. Dim PasteKey As New List(Of String)
      527. Dim PasteDate As New List(Of Integer)
      528. Dim PasteTitle As New List(Of String)
      529. Dim PasteSize As New List(Of Integer)
      530. Dim PasteExpireDate As New List(Of Integer)
      531. Dim PasteIsPrivate As New List(Of Boolean)
      532. Dim PasteFormat As New List(Of String)
      533. Dim PasteUrl As New List(Of Uri)
      534. Dim PasteHits As New List(Of Integer)
      535. Dim html As String = Postreq("http://pastebin.com/api/api_post.php", post)
      536. For Each m As Match In New Regex("<paste_key>(.+)</paste_key>").Matches(html)
      537. PasteKey.Add(m.Groups.Item(1).Value)
      538. Next
      539. For Each m As Match In New Regex("<paste_date>(.+)</paste_date>").Matches(html)
      540. PasteDate.Add(Integer.Parse(m.Groups.Item(1).Value))
      541. Next
      542. For Each m As Match In New Regex("<paste_title>(.+)</paste_title>").Matches(html)
      543. PasteTitle.Add(m.Groups.Item(1).Value)
      544. Next
      545. For Each m As Match In New Regex("<paste_size>(.+)</paste_size>").Matches(html)
      546. PasteSize.Add(Integer.Parse(m.Groups.Item(1).Value))
      547. Next
      548. For Each m As Match In New Regex("<paste_expire_date>(.+)</paste_expire_date>").Matches(html)
      549. PasteExpireDate.Add(Integer.Parse(m.Groups.Item(1).Value))
      550. Next
      551. For Each m As Match In New Regex("<paste_private>(.+)</paste_private>").Matches(html)
      552. If m.Groups.Item(1).Value = "0" Then
      553. PasteIsPrivate.Add(False)
      554. Else
      555. PasteIsPrivate.Add(True)
      556. End If
      557. Next
      558. For Each m As Match In New Regex("<paste_format_long>(.+)</paste_format_long>").Matches(html)
      559. PasteFormat.Add(m.Groups.Item(1).Value)
      560. Next
      561. For Each m As Match In New Regex("<paste_url>(.+)</paste_url>").Matches(html)
      562. PasteUrl.Add(New Uri(m.Groups.Item(1).Value))
      563. Next
      564. For Each m As Match In New Regex("<paste_hits>(.+)</paste_hits>").Matches(html)
      565. PasteHits.Add(Integer.Parse(m.Groups.Item(1).Value))
      566. Next
      567. Dim Paste As New Pastes
      568. Paste.PasteDate = PasteDate
      569. Paste.PasteExpireDate = PasteExpireDate
      570. Paste.PasteFormat = PasteFormat
      571. Paste.PasteHits = PasteHits
      572. Paste.PasteIsPrivate = PasteIsPrivate
      573. Paste.PasteKey = PasteKey
      574. Paste.PasteSize = PasteSize
      575. Paste.PasteTitle = PasteTitle
      576. Paste.PasteUrl = PasteUrl
      577. Return Paste
      578. End Function
      579. ''' <summary>
      580. ''' Deletes a paste
      581. ''' </summary>
      582. ''' <param name="PasteKey">The pastekey</param>
      583. ''' <returns></returns>
      584. ''' <remarks></remarks>
      585. Public Shared Function DeletePaste(ByVal PasteKey As String) As Boolean
      586. Dim URL As String = "http://pastebin.com/api/api_post.php"
      587. Dim APIUserKey As String = GetUserAPIKey()
      588. Dim post As String = "api_option=delete&api_user_key=" & APIUserKey & "&api_dev_key=" & dev_key & "&api_paste_key=" & PasteKey
      589. Dim html As String = Postreq(URL, post)
      590. If html.Contains("Paste Removed") Then
      591. Return True
      592. Else
      593. Return False
      594. End If
      595. End Function
      596. ''' <summary>
      597. ''' Returns the RAW data from a paste
      598. ''' </summary>
      599. ''' <param name="PasteKey">Your pastekey</param>
      600. ''' <returns></returns>
      601. ''' <remarks></remarks>
      602. Public Shared Function GetPasteText(ByVal PasteKey As String) As String
      603. With New WebClient
      604. Dim html As String = .DownloadString("http://pastebin.com/raw.php?i=" & PasteKey)
      605. Return html
      606. End With
      607. End Function
      608. End Class


      Kritik, Feedback und Meinungen zu meinem Stil sind erwünscht.

      Wenn ihr die Klasse einbindet/verwedet ist keine Namensnennung o.ä nötig.
      Dateien
      Gepriesen sei das Rauhe Haus,

      Ich hätte da doch mal ne kleine Frage. Warum alles als Shared Deklariert? Da wäre es doch einfacher wenn man die Klasse mit einen Konstruktor inzitialisieren würde der den API-Key Abfragt.

      LG, J Herbrich