Guice

Dependency Injection Framework

  • (2 Pages)
  • +
  • 1
  • 2

27 Replies - 4010 Views - Last Post: 12 July 2010 - 02:06 PM

#16 dorknexus  Icon User is offline

  • or something bad...real bad.
  • member icon

Reputation: 1256
  • View blog
  • Posts: 4,618
  • Joined: 02-May 04

Re: Guice

Posted 06 July 2010 - 11:46 PM

Let's take a step back here:
You took some AP classes and got hired as an intern, thus your're a professional software engineer?

You are advanced for your age I would say. You have a position that most college sophomores don't have. You are delving into reflection and meta programming at a stage in your education when most people are struggling with syntax. You're doing well and your on the right path to become a successful software engineer. Understand though, you have a long road ahead of you and a lot to learn. Not just experience. Computer science is a lot more involved than just slinging around code.

You went off on some spiel about how Java reflection is some advanced programming topic and DI is basically just dumbed down reflection. Ok, way to completely miss the point and the usefulness of dependency injection. It's called a "design pattern." Look that one up. Clearly you've never had to maintain a large piece of software. Yes, you are right, the DI framework does put to use reflection to get some work done. It's simply utilizing a feature of the language. So what? I don't understand how you figure Proxy and Method have anything to do with dependency injection. It's not trying to manipulate the functionality of anything at run time. It's just implementing a common design pattern, that's all.

Second of all. Manipulating an interface at run time, in Java is a complete violation of its purpose and type system. It is a statically typed language for a reason. Like I said before; if you want dynamic typing, use a language that supports it. Don't try to ghetto rig a language to do it. Not only will it be very difficult, but you'll end up with a type-unsafe program in the process.

Third of all. You are ooh'ing and aahhh'ing over Java reflections saying they are the future and all other languages are mostly likely inferior or will be if they don't "catch up". Honestly, Java's reflection is a sad, crippled attempt at some whack-ass version of "read-only" meta programming. It's better than nothing, but it's nowhere near as powerful as languages who depend on dynamic typing and meta programming to get shit done. Reflection is just one small piece of meta programming as a whole.

Go look at Common LISP and you'll see that most modern languages are still playing catchup with its feature set 40 years later.

This post has been edited by Dark_Nexus: 06 July 2010 - 11:51 PM

Was This Post Helpful? 0
  • +
  • -

#17 macosxnerd101  Icon User is offline

  • Self-Trained Economist
  • member icon




Reputation: 10803
  • View blog
  • Posts: 40,257
  • Joined: 27-December 08

Re: Guice

Posted 07 July 2010 - 04:37 AM

Quote

You took some AP classes and got hired as an intern, thus your're a professional software engineer?

I used the AP CS course to get across the point of how basic the course work was. At my internship, there isn't a ton of formal mentoring, and I do work right on par with my co-workers, who have been in IT a lot longer than I have (on the scale of 10+ years).

Quote

It's simply utilizing a feature of the language. So what? I don't understand how you figure Proxy and Method have anything to do with dependency injection. It's not trying to manipulate the functionality of anything at run time. It's just implementing a common design pattern, that's all.

I guess I got off on that tangent from my own experiences with reflection. My initial response was "ooh, this looks like reflection. but wait, why doesn't it do this then?" I'd say I'd have to use the framework or design pattern a little before I can say much more about it.

Quote

Honestly, Java's reflection is a sad, crippled attempt at some whack-ass version of "read-only" meta programming. It's better than nothing, but it's nowhere near as powerful as languages who depend on dynamic typing and meta programming to get shit done. Reflection is just one small piece of meta programming as a whole.

I guess I've enjoyed meta-programming thusfar, and I'd be interested to see how meta-programming works on dynamic languages. I'll have to play around with some of the languages you mentioned when I get a moment.
Was This Post Helpful? 0
  • +
  • -

#18 Programmist  Icon User is offline

  • CTO
  • member icon

Reputation: 252
  • View blog
  • Posts: 1,833
  • Joined: 02-January 06

Re: Guice

Posted 07 July 2010 - 08:42 AM

@macosxnerd101: I don't tend to look at people's profiles (I usually just take people as they present themselves), so I didn't realize you were still in high school. That explains the potential confusion with reflection and DI. No worries. It sounds like you are doing some interesting and pretty advanced work. Enjoy it and appreciate it because many software developers get stuck doing mundane programming assignments when they are first starting out. Your experience with Android will serve you well because that market is only going to get stronger.

And as far as me being "advanced"...well, you're only as advanced as your last gig. Stop learning and trying new technologies/languages and you'll be a relic in 6 months - maybe less. :)
Was This Post Helpful? 0
  • +
  • -

#19 macosxnerd101  Icon User is offline

  • Self-Trained Economist
  • member icon




Reputation: 10803
  • View blog
  • Posts: 40,257
  • Joined: 27-December 08

Re: Guice

Posted 07 July 2010 - 08:57 AM

Yep- going into my senior year of high school. Next year I get Discrete Math with a teacher who has a doctorate in math, so I'll use that to hit hard on as much CS theory as I can. And the most advanced programming class at my school is AP CS. While we have the best curriculum nation-wide (we're expecting all 5's), it's still only an intro course, so all my extras I mainly picked up from DIC. My internship is definitely fun and the work is awesome, and it's even better as I could stay on throughout college and get a high paid, full time job right out of school!

Quote

(I usually just take people as they present themselves), so I didn't realize you were still in high school.

Usually, people mistake me for younger than I am by looking at me, so I'll definitely take this as a complement. I'm glad that I'm appearing like I'm much older than I actually am. :D

Quote

And as far as me being "advanced"...well, you're only as advanced as your last gig. Stop learning and trying new technologies/languages and you'll be a relic in 6 months - maybe less

That is the exact opposite of what my co-worker said at my internship. He said that he only keeps up with what he needs for a job. Of course, I disagree with him, and I find it fun to pick up new technologies and design patterns, so there's no problem there.

This post has been edited by macosxnerd101: 07 July 2010 - 09:32 AM

Was This Post Helpful? 0
  • +
  • -

#20 dorknexus  Icon User is offline

  • or something bad...real bad.
  • member icon

Reputation: 1256
  • View blog
  • Posts: 4,618
  • Joined: 02-May 04

Re: Guice

Posted 07 July 2010 - 09:40 AM

Quote

That is the exact opposite of what my co-worker said at my internship. He said that he only keeps up with what he needs for a job. Of course, I disagree with him, and I find it fun to pick up new technologies and design patterns, so there's no problem there.


That's why your co-workers with 10+ years of experience don't know very much, they stopped experimenting. Experimentation is good, haven't you ever watched porn?
Was This Post Helpful? 2
  • +
  • -

#21 Dogstopper  Icon User is offline

  • The Ninjaducky
  • member icon



Reputation: 2876
  • View blog
  • Posts: 11,051
  • Joined: 15-July 08

Re: Guice

Posted 07 July 2010 - 02:43 PM

I'm even younger than macosxnerd101. I'm going into my Junior year. Unlike him, my school is not so good with the whole programming thing and I'm stuck doing everthing myself.
Was This Post Helpful? 0
  • +
  • -

#22 Programmist  Icon User is offline

  • CTO
  • member icon

Reputation: 252
  • View blog
  • Posts: 1,833
  • Joined: 02-January 06

Re: Guice

Posted 07 July 2010 - 02:51 PM

View Postmacosxnerd101, on 07 July 2010 - 08:57 AM, said:

Yep- going into my senior year of high school. Next year I get Discrete Math with a teacher who has a doctorate in math, so I'll use that to hit hard on as much CS theory as I can. And the most advanced programming class at my school is AP CS. While we have the best curriculum nation-wide (we're expecting all 5's), it's still only an intro course, so all my extras I mainly picked up from DIC. My internship is definitely fun and the work is awesome, and it's even better as I could stay on throughout college and get a high paid, full time job right out of school!


Man - I hope you realize just how awesome you have it. When I was in high school there was only one computer class and it was using an Apple IIe and programming Apple Basic. I had an IBM clone at home, but it only had 512K or RAM and no HDD, plus I really couldn't afford Borland C++ compiler anyway, so I was stuck with QBASIC. The internet as we know it today was also nonexistent. There were no mobile operating systems or even cell phones. My school was a small rural school, so I wasn't introduced to discrete math (Or anything beyond algebra and trigonometry) until my undergrad degree many years later. You have a HUGE advantage over people like me who graduated years ago in a podunk little town, so you'd better not squander it! Do something awesome! :)

View Postmacosxnerd101, on 07 July 2010 - 08:57 AM, said:

That is the exact opposite of what my co-worker said at my internship. He said that he only keeps up with what he needs for a job. Of course, I disagree with him, and I find it fun to pick up new technologies and design patterns, so there's no problem there.


When my wife asked me why I don't read a lot, I told her I do read - just not fiction. I described to her the "drink-from-the-firehose" mentality that a software developer must take to stay at the top of his game. Between books, blogs, news, white papers, experimentation, and other miscellanea I find a lot less time to read for "pleasure" than I use to - although I do consider what I read pleasurable or I would change careers. There is something to be said for having a life outside of development, so balance is important, but it sounds like your co-worker has just given up. Maybe it's time he moves into management. :)
Was This Post Helpful? 1
  • +
  • -

#23 macosxnerd101  Icon User is offline

  • Self-Trained Economist
  • member icon




Reputation: 10803
  • View blog
  • Posts: 40,257
  • Joined: 27-December 08

Re: Guice

Posted 07 July 2010 - 03:56 PM

I do feel really lucky to be in the IT Specialty Center at my school. We've got an awesome curriculum, and an overall great set of teachers.

Quote

Do something awesome! :)

Thanks! I'm certaintly trying to do this. I've written a Java program for my school's laptop help desk, and I'm writing a huge Drag-and-Drop program for the assistant principal at my school, who wants to help me make money off of this by piloting this into my school system as well as neighboring school systems. I don't know if you read my blog entry on my nonprofit website project, but that had a huge scope as well.

In regards to the reading, I'm the same way. It's really funny, as on a couple tabs I usually have DIC open, and on another two tabs I have the stock market and financial articles open. I've yet to be able to get through all of Going Rogue yet, as I just don't have the time (it's also comical here, as I'm reading Palin's book and my mom is reading Obama's book).

I don't know what's going on with my co-worker, as he has a bachelor's degree in CS, but I know he was originally hired as a PHP developer. I do know that he is the only full time employee at this office, and my boss travels a lot to other offices out of town.
Was This Post Helpful? 0
  • +
  • -

#24 Programmist  Icon User is offline

  • CTO
  • member icon

Reputation: 252
  • View blog
  • Posts: 1,833
  • Joined: 02-January 06

Re: Guice

Posted 08 July 2010 - 09:03 AM

Ok, you lost me at "Going Rogue." Please tell me you checked the book out of the library (or borrowed it from someone) rather than buying it and therefore donating to her 2012 campaign.
Was This Post Helpful? 0
  • +
  • -

#25 macosxnerd101  Icon User is offline

  • Self-Trained Economist
  • member icon




Reputation: 10803
  • View blog
  • Posts: 40,257
  • Joined: 27-December 08

Re: Guice

Posted 08 July 2010 - 09:24 AM

My parents got it for me for the holidays. She actually came to my school during the campaign for a rally, and I got her autograph, shook her hand, spoke to her, and got a really good picture of her with my phone. I really like her fiscal policies, though she has a lot of room for improvement before she's ready to be president.

But anyways, I digress to something off-topic. :)
Was This Post Helpful? 0
  • +
  • -

#26 Programmist  Icon User is offline

  • CTO
  • member icon

Reputation: 252
  • View blog
  • Posts: 1,833
  • Joined: 02-January 06

Re: Guice

Posted 08 July 2010 - 09:45 AM

Well, you'll be old enough to vote in 2012, but I can assure you that she will not be "ready" to be president for a long long time, if ever. Do some more research on Palin (not on pundit or conservative websites).
</off-topic>
Was This Post Helpful? 0
  • +
  • -

#27 macosxnerd101  Icon User is offline

  • Self-Trained Economist
  • member icon




Reputation: 10803
  • View blog
  • Posts: 40,257
  • Joined: 27-December 08

Re: Guice

Posted 08 July 2010 - 09:52 AM

I will. And don't worry, Glenn and Rush are just as nauseating to me as the left-wing pundits as well. I'm very much independent.
</off-topic>
Was This Post Helpful? 0
  • +
  • -

#28 sbromley  Icon User is offline

  • D.I.C Head

Reputation: 21
  • View blog
  • Posts: 127
  • Joined: 20-May 09

Re: Guice

Posted 12 July 2010 - 02:06 PM

If you all don't mind I'd like to bring this back on topic.

I've been using spring for a while now, and I remember a guy on the team toying with Guice with some of our services. For the people that use it or have used enough to be comfortable with it, what are some of the major differences? I know that Guice came out with the whole annotations before spring did, but now I'm using annotations in my spring based configs. Are there any major advantages to Guice?

This post has been edited by sbromley: 12 July 2010 - 02:06 PM

Was This Post Helpful? 0
  • +
  • -

  • (2 Pages)
  • +
  • 1
  • 2