#dev-general
1 messages ยท Page 435 of 1
if everyone developed their own library we would all know SOLID in no time
unless they are designing a shitty
library
they are either way, the point is that they work too
Take java collections
I don't see how they wouldn't work
When you see retrooper making every possible field public 
If they are in the parent class
You can override methods
Yeah
So sometimes people have methods just do nothing in a subclass
in his packet api?
lol
List<String> list = new ArrayList<>();
list.add("");
```this works```java
List<String> list = List.of();
list.add("");
```this blows up
This is fine though? No?
(:
No he argued for half an hour trying to prove public fields are better pulse lol
Idk maybe
No
It kind of defeats the purpose of subclasses
All child classes must have somewhat of a similar outcome
So, all methods in the parent class should also be used in the subclasses?
lol his packet api is a mess but also not a mess
it follows some conventions
but not others
As in, If you were to use the parent somewhere, all child classes must be substitutable in its place without breaking anything
Of course valdemar it also depends on your needs for instance we might have the classes
Animal
Leopard
Dog
GoldenRetriever
Labrador
yes, exactly that
If you need Animal then of course go with Animal, if you need dog go with Dog
It's a principle to apply when you extend or implement a type
They are a type of the parent class
They are different "Implementations" of the parent class
The way it does something may differ
But the outcome must be similar
or justifyable
Like a database class, if you have an sql database class and yml database, they both might have a save() method, but save differently
Forget "How", focus on "What" ๐ , guess where this is going
Antarctica?
Lol
Alright, pretty sure I understand now
that.. size.. doesn't matter?
๐
๐
Wait so dependency inversion is just liskov?
๐
๐๏ธ๐๏ธ
Well, no
They are related tho
Forget "How", focus on monadmonadmonad
hey kid, wanna buy some...
๐๏ธ๐
๐๏ธ
monads?
registered haskell offender
oo oo how much for a pack???
buck fiddy
They focus on different things
What was that
wot
an illegal link apparently
invite link
Bot?
with a wall of text
lol
he posted a discord link
sadge
Which different things though?
@hexed kettle lmfao
they say fundamentally different things.
LSP just states that you should be able to replace any type with a subtype, while dependency inversion says you should depend on abstractions rather than implementations
One as Johnny said substitutable subtypes, one depending on high level (abstraction) instead of low level which often would be done by dependency injection
Oh yeah what Johnny said
ServiceLoader good or bad
yes
What is the difference between abstractions and implementations though? Not sure I understand it correctly then
No idea pulse
Abstraction: List, Implementation: ArrayList
ArrayList is also a list though?
It is
Yes
Implementations implement an abstraction
ehhh what
Heres a easier way to think:
Abstractions define what is to be done,
Implementations of these abstractions define how it is to be done
So at a high level, you should only care about what is being done, rather than how it is being done
How can there be more than one way to do it though? When you say how
Itโs good I mean in Bukkit we have services manager so probably use that I guess
But just in general ServiceLoader would be nice
An example is mathematical formulas. There are many types, but all would probably have on method, calculate(). So all you have to do is pass in the numbers, you donโt need to know the specific formula.
There are always multiple ways to perform an action.
Lets take a very simple example, You want to fetch the name and age of a person, this is the what, i.e, "fetch the name and age of a person"
This could be achieved through a number of different ways such as by a web request, a db query, or whatever else, each of these are the hows
Makes sense, so what is "high level" based on importance for the program/plugin or what?
Valdemar I would generally say that interfaces are functionalities where they specify a behavior. Abstract classes are data structures which have a common code for reusability. Then normal classes are just data structures. You implement an interface/functionality, you extend a data structure/class. Probably off topic what I said but ye๐
High level as in the action it performs, its relative
Kinda makes sense, I think I'm a bit too tired to understand that for now though lol. But I saved it to some notes.
But got a little problem, how come I need to add it to a final array?
the boolean
Because of how captures work, you cant mutate captured values, you can only mutables things that this value holds references to
Yeah cause Java doesnt want to access an object while its being modified
you can either use Atomic or make it final
Yeah what yugi and pulse said
atomic has blocking
Why does java not like that though? And how is it being modified while Im getting it?
Because it's in a runnable?
its not always the case
but it could
happen
so thats why its enforced
never a guarantee
but C++
Valdemar itโs actually to prevent memory leaks
Rly?
Ahhh kk
Yes
Because its in a separate class
some random ass thread could just peek up and modify the object
even if it doesnt exist
That method there is implemented by you, not necessarily run. Letโs say youโd be able to reference variables from that method inside the run method then it would have to keep track of that variable even though the outer method might have ended termination long time ago.
It simply passes the required variables onto the anonymous class, and since java is pass by value, the reference inside the anonymous class is different but just pointing to the same object, mutating this object only changes the object inside the anonymous class
Which is why java disallows this
ahhh okay
C# allows this and generates a intermediary reference class but that just leads to another set of problems
๐คก
I kinda wanna start learning C#
Sure, give it a go
Is it worth it to put a bunch of time and effort into getting Minecraft in java 11?
Mostly to try out game development in Unity though
yes
Not much difference chestly
Thats what I mostly use it for as well vald
Ik, i just really wanna use the module system
not much difference to change and people can finally UPDATE
but alright, thats all i need to know
For how long have you been using Unity?
lwjgl uses sun.misc stuff so i might eventually just need to re-write part of it...
About 2 yearsish, part of the curriculum
Because I think I'll start out with Unity then after some time I'll maybe go over to UE because it's better but more difficult
I think
Less limits in UE
UE has a much better visual scripting system
Unity is way easier to begin with when I have basic java knowledge though, at least I hope I do lol
Since C# is a lot like Java
C++ is a great language change my mind
Changed. There we go
literally everything you like about it
i have to call destroy every single time i type new
performs lobotomy
lol
I mean Java depends on C++ right?
no, html actually
The compiler, yes
compiler is built on html
Yes, but its now written in java itself I believe?
Didnt they use to use Java in web broswers instead of JS or something?
applets, yes
yikes
Security vulnerabilities
exactly
๐ฅฒ
ew
Yes, but it might as well be written in anything
h
coffeescript
well duh lol
When your Java installation completes, you may need to restart your browser (close all browser windows and re-open) to enable the Java installation.
That was my only point pulse
but in general, they should be written in C/C++ lol
Why?
thats it im only writing in that now
Correction: Low level languages
Rust is low level?
Well yes but actually no
lol
even c++ is high level in a sense
But if you consider c++ low level
so is rust I assume
Yeah
why is objective c considered one of the worst programming languages of all time?
is it that bad?
If you want to get technical no programming languages except assembly languages are low level
^
If C++ is considered high level what is python
I mean C++ is a high level language, but it allows for low level crap
skyrocket high
lmao
still, high level
C++ on drugs?
Yea got caught smuggling monads

Want a pack?
E A T
ramen?
Yummy
What time is it?
ramen
eat ramen at 1 am
I suppose the question is what you define high level as. Do you define it as "relatively moved away from the hardware" or "supporting abstract programming concepts beyond the cpu instructions"
Ramen time
spicy
Makes sense
Then just have lunch ig, is it normal to have ramen in the after noon?
idk
Sure
ok adios
ciao
Both is right or no?
you talking about ramen like the fast one?
where you just add hot water
or like actual ramen
Yes, but the second one is a lot stricter
What is the "actual" ramen?
ik, but i havent been
Hmm interesting Johnny. Havenโt really thought about that one lol
Ramen () (ๆ้บบ, ใฉใผใกใณ, rฤmen, Japanese pronunciation: [ษพa๊หmeษด]) (literally: "pulled noodles") is a Japanese noodle soup. It consists of Chinese wheat noodles served in a meat or (occasionally) fish-based broth, often flavored with soy sauce or miso, and uses toppings such as sliced pork (ๅ็ผ, chฤshลซ), nori (dried seaweed), menma, and scallions. Nea...
No
Gonna save it (:
chao mien is like stir fry noodles
Yea
Is ramen not fried?
not always
Ramen noodles (:
we need #food back ๐ซ
So just boiled?
That sounds.... mildly... disgusting
how could fried noodles possibly be disgusting
i didnt do that obviously. i bought one from a brand
worst you can get is they taste like nothing
Wouldnt boiling without frying just make it watered down dough?
Non-fried john
Just boiled
Johnny*
No I just prefer calling people without the ending ys
I do the same for gab
Have you never eaten non-fried noodles?
Johnathan :)
Nope
Lmao
lol ok
๐
it's very common
Better than fried?
i mean, they are good in their own ways
Did someone mention fried noodles
https://www.youtube.com/watch?v=Ani_6IRV20A
pink guy wants to die
TWITTER: https://twitter.com/FilthyFrank
FACEBOOK: https://www.facebook.com/TheFilthyFrank
SHIRTS: http://filthyfrank.spreadshirt.com/
INSTAGRAM: http://instagram.com/papafranku
MUSIC: http://pinkguy.bandcamp.com/
Non fried noodles 
Alright, I need to find a place that sells these
Although, I commonly see soup noodles (the boiled noodles) pretty common around my area
Find yourself an Italian restaurant
I might just order home
oh god
lol
perfect
that looks like a pot
probably a bowl
Boil it?
lmao what
Cursed
I'm gonna eat it cold
please dont lmao
you will throw up or smthing
it wont taste good
Ok ok
f my scoreboard isn't working
sounds like a not my problem
:c
You already put it in water
or add hot water and stir it
The water is boiled
Idk a month?
a few years, give or take
lmao
Right
my mom be like "either way you are getting the nutrients bro. It's just in a cheaper way"
idk what the fuck an inside out bowl is
Is this how it works?
xD
Oh yes, definitely
lol
Yum time to eat
dont forget to heat it till the plastic melts
Thats where the flavour is at
Yeah the plastic
Yum
For the extra flavor, tap in some bolts and screws
do you know those silica packets from packages
Yeah lol
Ohhh tasty
awesome flavour
ikr
im not capping, but you can eat those without dying unless you eat like 20 of those
yeah lol
They aren't super harmful but they will taste nasty
Sounds like someone has tried ๐
lmao nah
lol
Vladmir Putin the Second?
What is this name xD
you can find big threads online of people discussing the taste
Nooooo u cant just eat silica gel packets for breakfast
I have a podcast second channel at @Heme Review
See references below to read more about silica gel
A Man Had An Accident With A Weight Loss Chemical. This Is What Happened To His Organs. โบ https://youtu.be/ChPeG19qKUo
A Man Swallowed A Fishbone. This Is What Happened To His Liver. โบ https...
eww
Please delete that embed
tf is that
the forbidden cauliflower
a bust lung?
lol
never knew it would that tasty
Credit
LEGO Train: https://youtu.be/emP0en2gtHI
LEGO Rescue Helicopter: I actually filmed that myself since I couldnโt find a clip of it and I said to myself โwhy not use the toilet?โ And I threw my LEGO copter into the toilet no questions asked, the video must go forth.
LEGO Police Boat: https://youtu.be/XvbFzpVdJQ0
LEGO plane: https://youtu.be...
Fuck state, Im just gonna have this write to a db and use that for reactions
๐
lol
Can raw pork kill you?
yes
Perfect
According to "Contagion", it might also kill about a million people or so
There's that one picture of the insides of a woman who only ate raw meat for years or something
Its disgusting af
ew
Everything full of worms
๐
there it is
who the hell eats that shit
A chinese woman
On that note good night
Food
ah a fancy college student eating ramen nice ๐
I, too, have like 30 things of ramen in my pantry
Who says im in college?
ur mom
lol
Im in the streets
that's just the typical college meal
fending for myself
oh
well makes even more sense
he writes it on the sidewalk
trash can coding
and someone codes it for him
or that
lol
in the coals
what if you took an arm
I have this large 20 pack of ramen
lol
standard
Where do people get these nice profile pictures?
which ones?
mine kappa
any of them
wel
the nice custom ones
Someone make one for me
lol
which ones are u talking about
probably like Gian's or Skylar's
they make em
blitz's pfp tho
what about mine
ugly
i want
๐ฅฒ
blitz pfp is a masterpiece
That's just a selfie
damn u sexy
I wanna sex
Same
same
wow what a bunch of virgins
lmao
๐ฅฒ
Welcome to the group
my girlfriend isnt a virgin
but im not either
/s
i have no gf and im a virgin ๐ฅฒ
k
You're young though
you got it all figured out!
anyone want to help test out my bedwars plugin :p
;-;
or
lmfao
Did you guys see how nice console commands look on Paper now while you're typing them?
o.o
Trying to replicate the in-game look & feel
red for unknown cmds
or invalid cmds/argumends
Ive told you so many times
not me
I wont expose my ip which is 192.0.0.1
i have best ip
i mean
no
not eastern
dumbo
no
im tired too okay
chestly time
lol
west coast
well you have a reason to
what timezone?
I also mountain
what
yes
are you in arizona
ive told you where i live too
not in mountain then
my exact adress
it's 7:44pm in mountain
your neighbor's
exactly incorrect
fucking what
entertain me
cause
well
I dont have stuff due till friday
and im tired
so its not happening
bro next week is finals week for me
I just gotta finish out a few assignments and then take my finals and it's over
I have two full months left, though monday was actually my first day in person in like 13 months
so that was interesting
yo so Im learning how to use maven? Except for one of the plugins im looking for a repo for i cannot find, can I still use the normal intellij dependencies(add jars or directories) and maven dependencies for my project?
first off, yikes to the maven thing
and second, yes you can use local libraries you download, just put them in a libs folder and add them to your maven local
ew lib, wait i have one in every project ๐ซ
so ok im in my .m2 repositories folder, but how do i go ab putting my local dependencies into the project
?
I was really dumb like 2 months ago and i made a dependency mangaement thingy that would search a directory for jar files and either install them in maven or gradle
it didnt work and caused me pain
well it did work actually
but not wel
thanks LOL
Don't use system scope though
Yet another reason for me to be even lazier when considering fully switching to linux
i gleefully await the day they announce they're replacing the Windows backend with a POSIX compliant one
lol
then you can install the Windows desktop environment on any linux system >:)
It's even on GH, nice https://github.com/microsoft/wslg
They do
Meaning both in a corporate strategy way and in a literal way lol
wtf is happening
oh only for images though?
I can't seem to remove that one without deleting the message
I mean I literally just copy/pasted like I'd do with an image
and in there it just says "attachment"
that is very clearly an attachment
unless
maybe it needs a message too ๐
yep
Thanks I was looking for the pin assignments for the MC68H(R)C908JL3E
I gotchu bro ๐ช
finally I can manufacture my.. uh... button?
You dontt
Literally no life smh
no u
Ooo i'm almost passing Aboo
Lol

๐
You mean good morning right?
No
Fix your sleep schedule nerd
Never
K nerd. You finally did yours and noe you are acting all cool and shit
Mine was never fucked to begin with
hi
it is night
Itโs like 12 am and Iโm writing shitty code
Someone help lmao
Who wants to see the shit code
Ive decided to switch over to only using sun. classes
I good coder
and i got this wanky new compiler that doesnt complain when i do it in java 11
i mean what?
show
though i will hate on u if its better than mine
ftr
no it must be truly trash
why would you check it in if its that bad??
Cause Iโm about to sleep
And when I wake up I gotta go somewhere
And I bring my laptop
#heavyweight constructors
Which got the IDE
lol
Yeah
Thatโs what Iโm talking about
The constructors are so DRY
final File downloaded = new File(library.getImageFolder().toFile(), FilenameUtils.getName(url));
try {
FileUtils.copyURLToFile(new URL(url), downloaded);
} catch (final IOException e) {
e.printStackTrace();
}
images = ImageUtilities.getFrames(downloaded);
frameDuration = ImageUtilities.getGifFrameDelay(downloaded);
scheduler = Executors.newScheduledThreadPool(1);
Mhm
in a constructor ftr
I need to sleep lmao
why didnt you just put that in your build method of the builder?
Pulse, im disapointed, i dont see any sun. usage here
Well ideally, i would put it as its own method
Why use string when you could allocate and set space with Unsafe?
Yeah
I got this great native library that adds pointers and everything into java too
And it will shut down the jvm if you try to use any features that make java java
Im not funny
๐ฅฒ
The only thing I hate about it is the stupid destroy thing
lol
Though it makes sense
Cause there ainโt any GC
Wait until you hear about smart pointers ๐
Whatโs that
Coding in C++ actually requires skill cause if you fuck up pointers you could just cause memory corruption Lmao
smart pointers are just pointers that make you want to end your life less
Kek
I would be a dumb pointer
I made snake in C then i was like, great goes on My resume and im done
lol i didnt actually put it on my resume
that would be funny though
wdym, i love just reading forever from an array and seeing what memory pops up!
Well you just forget about new and delete
But it's a tradeoff
best way to get passwords
Because then you have to think about ownership
i'll own you
๐ณ
is kinda like rust
When did the erp start?
C++ be livin on the edge
She-Ra :)
you like?
Im binging, what platform
no silly it's He-Man
now import every single class in the jdk
Lmao
really?
wdym what platform then
lol
netflix is like, the most default
MML finna be payin for Pulse's netflix subscription
I donโt get any money lol
I do it cause of motivation
Oh
xD
Stars on a gh repo surprisingly motivate more than I thought
You can be another SuperDeluxeAsyncWhateverItsCalled
Yes lmao
i know i know, i'm very motivating
Yes@
coke
Im so sad, ive never gotten a star 
yes
impossible
I come closer 3 inches everytime I push a commit
also why the integral symbol look like shit
Idk
it looks like its got a thing in the middle
Itโs all your fault
๐ฆ
๐ฎ
Looks fine on mobile
how silly would it be to only access an sql db from one connection pool on one server, and use sockets to request a query through that pool
rather than connecting straight to the sql db from a bunch of servers at once
why]
because connection pools eat up a lot of connections
and sql can't exactly handle infinitely many
how many servers we talkin
cause im sure it can handle like 4-5 servers at least wroth
who tf has 30 or 50 servers
i hope to :3
not even like hypixel does that
i know but they don't all connect to a single sql database lmao
exactly
that's when you use other kinds of databases
hm
they probably use Mongo where Mongo is useful
using Mongo to store permission/punishment data is a curse
but Mongo has its uses
Yeah in that sense presumably
Mongo is basically a frontend to JSON, meaning you can store objects within objects
which is useful when you want children that are not repeated
The point with mongo is to store unstructured data tho
(e.g. Paperโs downloads API uses Mongo because it allows them to have all the builds under a single version object, and further down the tree)
Ew, you want children?
not true
Yes thatโs what itโs main usage is for
on a serious note, yes I do, but thatโs not what I mean here of course lol
JSON isnโt unstructured
The data is unstructured not json lol
Mongo is a frontend to JSON
all Mongo data is stored in JSON
thatโs just a fact
Bson
JSON data is unstructured
You can impose an additional structure, but it's not required for json
fair
Yes itโs stored in json format? But itโs able to handle unstructured data at a good speed thatโs like itโs main usage and itโs an irrefutable fact
true I guess
example of where Mongo sucks though is LuckPerms
since you need an entry to relate to other entries in other tables
Yeah thatโs probably one instance
(users have their permissions in a different table, and those need to be related)
Havenโt personally thought about that but it sounds correct not to use mongo there
but Mongo triumphs for unstructured and non-relational data, for example the Paper downloads API
Hmm yeah I mostly use it for logs
who tf stores logs in a database table
do you know what a log file is?
I just use RollingRandomAccessFile in my Log4J 2 config and it handles all the logging and GZIPping for me
may or may not have stolen it straight from vanillaโs Log4J 2 config
Lol yeah Idk I mean the data is unstructured and it wouldnโt need a lot of files
the only problem with my thing is that with the amount of times I start and stop Krypton, you end up with a hell of a lot of old zipped log files
ur still meant to have a strict schematic when using mongo
I mean, they take up very low amounts of storage (GZIP seems to be able to compress like 10 MB worth of text log data down into a matter of kilobytes), but it still makes me scroll
yeah it doesnโt make sense to use a database without at least some form of structure or organisation of your data, if you have no structure then you might as well just shove it all in the same file
an unstructured database is about as useful as a chocolate fire guard
the whole point of databases is so you can organise data into something that wonโt make you go insane
As a what now?
chocolate fire guard
lol
I wonder if any other British people here have heard that one before
not sure if itโs a British phrase, English language phrase, or just not a common phrase at all lol
that is not true
No?
I have not
The point of databases is to store data, first and foremost
Idk why working without a schema would render your schemaless supporting database useless
Iโm just too distracted by the โchocolate fire guardโ rn
but whatโs the point in using a database for unorganised data? if you want unorganised data, you might as well just store it all in a text file
Letโs put it in a database then my pc wonโt go brrr anymore
"I can add attributes to pieces of data as I like"
"well why don't you store everything in a text file then??"
Wait a second thatโs not how this works ๐ฑ
I donโt use databases enough Iโm just lazy to create them as Iโve never learnt all the theory behind them
And if we get to entirely different databases it doesn't even make sense to force the use of a schema
look at datalog
Sure you can use schemas and you probably should when you can, but for the layout of the database it doesn't matter at all
The only thing you really get is indices
fair point
unorganised data is an anti pattern though, as itโs not going to be very readable is it
Youโre still going with this ๐คฆโโ๏ธ
lol
I've heard "chocolate teapot", never that
yeah my stepdad uses that one too
tempted to showcase Krypton lol
because why not
please elaborate on that
that just sounds like you threw a bunch of buzzwords together
if everything is all over the place, and basically unreadable, what use is it to you?
well... yeah, but what kind of point is that? Putting all your data in /dev/null is useless too and nobody is arguing that
lol
facts
imagine putting all your data in /dev/null yourself though
/dev/null as a service
blockchain modern pragmatic inversion principle
ai blockchain deep machine learning python algorithm
๐ฅฒ
Clojure vectors are faster than Java arraylists confirmed??
676.048785 +- 64.531253 ms/op
860.381775 +- 200.338442 ms/op
(adding 1M elements to an empty collection)
I wonder where the big error for arraylists comes from
Big error?
10 iterations with 3 forks
@lunar cypress are those tests ready to run?
nope, some are still skipped for some reason that I'm trying to find
should Java vectors be used where the data will most likely be resized often?
the jmh gradle plugin doesn't put thousands of null bytes in the results file anymore at least
I don't get how that plugin works
while it's running it has a text file with all the tests in plaintext
then once it's finished it's all converted to hex
surely I'm missing something
no
No, you provide the result format you want to have
oh so when we did it before, you manually set it to that?
no, I set it to txt or csv
the fact that they put null bytes in the results file was a bug
apparently
because it's gone 2 patch versions later
and now they put the interim results on stdout
which also makes a lot more sense
last time I personally used jmh though it wasn't like that
maybe I used it differently
what was it like
.
just checked, I was using the plugin too
but it didn't use the same default behaviour
this is non official
yeah that's the one I used too
there is no official gradle plugin
o
which version did you use
0.5.2
then they must have introduced a bug
or my shit memory is making things up and idk what i'm talking about
also I just realised that picking a random index from 0 to a fixed size when the collection size is getting smaller continuously blows up
I'm a genius
hi, can anyone tell me how to create my own MySQL database, because i never did it before
on localhost?
ye
install MariaDB first
okay, give me a sec i will install it
if you're installing mariadb you'll probably need to uninstall mysql first
