Welcome to the Java Programming Forums

The professional, friendly Java community. 21,500 members and growing!

The Java Programming Forums are a community of Java programmers from all around the World. Our members have a wide range of skills and they all have one thing in common: A passion to learn and code Java. We invite beginner Java programmers right through to Java professionals to post here and share your knowledge. Become a part of the community, help others, expand your knowledge of Java and enjoy talking with like minded people. Registration is quick and best of all free. We look forward to meeting you.


Members have full access to the forums. Advertisements are removed for registered users.

Results 1 to 3 of 3

Thread: Help me with ideas

  1. #1
    Junior Member
    Join Date
    Aug 2014
    Thanked 0 Times in 0 Posts

    Default Help me with ideas

    Hi there,
    I am quite junior in java currently doing a simple project, where there is a log in field, and one id and password is hard coded so that one can login anytime. if one logs in, A panel appears and there are some stuffs which admin can do, like adding new admin, deleting admin, and so on.
    If they click on add admin, the added name and password containing information can be used for further log in and he can do the same stuffs like the first admin.

    So my query is regarding The adding process. initially, what I am thinking now is, if admin clicks the add admin button and fills up the name and password, then the info's will be serialized or will be written in a text file with maintaining order. Then if admin tries to login using the information that has been written in a file, file will be searched for that specefic id and password and will be given access if matches.
    Is it good!
    I know it is not so cool process.
    Also it will be great to know, If I can use serialization and deserialization.

  2. #2
    Super Moderator
    Join Date
    Jun 2013
    So. Maryland, USA
    My Mood
    Thanked 698 Times in 680 Posts

    Default Re: Help me with ideas

    I'm not sure what your question is. Are you looking for feedback on the proposed design? It seems you already recognize it's not ideal, because user names and passwords should not be stored in text files unencrypted or at all. However, it may be an okay approach for learning purposes in an application that will never see actual use.

    Try to state your questions clearly - question marks help - or describe how we can help.

  3. #3
    Junior Member
    Join Date
    Jul 2009
    Thanked 1 Time in 1 Post

    Default Re: Help me with ideas

    you should be using a database for doing that.Yes, using serialization, you can write the byte stream to a file, but that is not exactly the purpose of serialization.If you indeed want to use a file for these operations, then use Java I/O..But then you will have to face these basic problems like, what happens when you want to write a data a simultaneously read from the same location ?

Similar Threads

    By ash12 in forum What's Wrong With My Code?
    Replies: 2
    Last Post: July 21st, 2012, 04:52 PM
  2. Game Ideas...
    By SupportIsPower in forum Java Theory & Questions
    Replies: 0
    Last Post: March 11th, 2012, 03:03 PM
  3. Any ideas?
    By ahender1 in forum What's Wrong With My Code?
    Replies: 3
    Last Post: February 2nd, 2012, 03:58 PM
  4. Any Program Ideas?
    By Java Programmer in forum Java Theory & Questions
    Replies: 7
    Last Post: January 18th, 2012, 08:05 AM