Mobile Agent serial number

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • ITstudent99
    New Member
    • Nov 2006
    • 3

    #1

    Mobile Agent serial number

    Hi every one I just I wonder if any one can help

    me and my colleague . We are developing a localization algorithm for mobile agent .

    and I need the java code that will help me to generate serial numbers
    to assign them for mobile agents

    I hope that someone will help me

    Thanks
  • sicarie
    Recognized Expert Specialist
    • Nov 2006
    • 4677

    #2
    Originally posted by ITstudent99
    Hi every one I just I wonder if any one can help

    me and my colleague . We are developing a localization algorithm for mobile agent .

    and I need the java code that will help me to generate serial numbers
    to assign them for mobile agents

    I hope that someone will help me

    Thanks
    What are you looking for in that serial? For it to be a certain number of digits long? In a random order, or a sequential? For it to then input into a certain type of db? and if so, what type?

    Comment

    • ITstudent99
      New Member
      • Nov 2006
      • 3

      #3
      Hi ...... thanks for your reply

      what am looking for is a random serial number of maybe 2 to 3 digit along

      so that whenever an agent is created a unique number is assigned to it

      and that number will be the ID of that agent.

      please feel free to propose any suggestion.


      thanks

      Comment

      • ITstudent99
        New Member
        • Nov 2006
        • 3

        #4
        hi guys

        i just want to know if any one has a solution for my problem??

        i need it as soon as possible .

        thanks

        Comment

        • sicarie
          Recognized Expert Specialist
          • Nov 2006
          • 4677

          #5
          Originally posted by ITstudent99
          hi guys

          i just want to know if any one has a solution for my problem??

          i need it as soon as possible .

          thanks
          I'm sure there is a solution, but are you just writing a program to simulate this, or are you trying to interface it with some sort of real-time database, have an actual production solution?

          If you're just writing the program, it's as easy as creating a random number generator within 3 digits, making sure it hasn't been created yet, and storing it in some sort of hash table or list.

          If this is for a production environment, it's more complicated in the db/device connections, but theoretically the same idea - the only problem will be having the devices themselves accept this number, figuring out how to send the devices the serial (the format)...

          Comment

          Working...