• 1 Post
  • 20 Comments
Joined 1 year ago
cake
Cake day: June 24th, 2023

help-circle
  • Lysergid@lemmy.mltoProgrammer Humor@programming.devLanguages
    link
    fedilink
    arrow-up
    5
    arrow-down
    1
    ·
    edit-2
    4 days ago

    Library built this way because it supposed to be flexible and provide ground for complex usecases. It can only be flexible if your API works with simple abstractions which you can then compose. It’s not driven by “I need this specific utility for this specific scenario”. That would be zoo you have in JS where you have 10 ways to iterate over array and 9 of them wrong for your scenario.

    Java’s OO is great because they design library with SRP in mind making sure there is few but good ways to do things.

    BufferedReader cannot accept file name because it makes arbitrary reader… well buffered. It’s not BufferedFileReader, even that would accept something like Path or File, not string, because File can be remote file, should Reader now know all possible local and remote protocols and path formats? What else it must do?

    Having it designed the way it is, allows Java to have utilities for various scenarios. Your scenario covered by standard lib too. See Files.readAllLines which, surprise-surprise, built on top of BufferedReader.











  • Kinda, I guess we all can agree it’s more typical to deserialize into POJO where theres is no such thing as missing field. Otherwise why would you choose Java if you don’t use types. This great precondition for various stupid hacks to achieve „patching” resources, like blank strings or negative numbers for positive-only fields or even Optional as a field.


  • You talking about those forcefully recruited after being blackmailed into accepting Russian passport or those who already had it before 2014 and were sent there after? Yes, sure, there are people who genuinely wanted those regions to be part of Russia. As there are Russians fighting on Ukraine’s side. Following your logic Ukraine or other “high moral” party should’ve run “special military operation” to help Russian Freedom Legion to overthrow Putin. Why not mentioning Crimea’s tatars in Russian army? Is it coz they were repressed, their property was taken and they were forcefully moved out of their native lands? Why their ethnicity is not that important? Can’t absorb Russian identity nationalism to the degree they blindly follow their tsar? Or better tell us if Russia is so pro-ethnicity independence then why Russia taking down those Dagestan rebels? Or not giving Siberia’s people independence? “That’s all western propaganda” you’ll say. Don’t bother.

    I’m join my neighbor in request to you to fuck ff. Don’t make me mad and keep “your” imperialistic opinion for Russian Empire fan meetup. The only anecdote here is you







  • As a non-native speaker I find woman more offensive than female. Noun male/female puts all as equal. Girls, boys, birds, ponies. Woman, though, seems to be de-attached. Especially when talking about humankind it’s common to refer to humans as just „man”. „No man been there”, „for all mankind”, „dog is a man’s best friend”. As it applies to man only and woman doesn’t count