webMethods step by step creation and implementation of Hash Table
Feb 04, 2013 17:42 3 Comments Development Vikram

 

webMethods step by step creation and implementation of Hash Table:

 

Go to wMPublic.pub.hashTable and copy all the services in your empty flow:

Specify the below input and output variables.

alt

Your Create HashTable service would be creating HashTable(to store your key and references)

alt

If you run it it will show the below output (empty HashTable) created

alt

Now, map and execute the put service, used to put key and value pair in your Hash Table

alt

When you run the put service after mapping, the output will be the Key 'A' and the value 'a'

alt

Again insert one more Key and value pair in the HashTable.

alt

After you run you can find the result with two key and value pairs

alt

Listkeys service is used to list all the keys in your HashTable

alt

Result after running will be the Keys (A and B)

alt

Likewise you can get the value of a Key by passing your key

alt

Result for Key B value is b

alt

Service size is used to get the size of HashTable

alt

Since we have inserted only two key and value pairs, the result(size) is 2

alt

Prev Next
About the Author
Topic Replies (3)
  1. 1
    idnkx user

    Shueb

    Hello, Is it put possible to use hastable.get service in different service as it using hatable as input. In this case you have created the hastable and retrieved the data(get) in the same service. I want to create a hastable in differnt service and hashtable get in differnt service

    1
    idnkx user

    SOUNDARYA

    Hello, Thanks for replying. I am bit confused on this.I have two services ServA and ServB in a ServA i am creating hashtable, and I want to get the content of same hashtable in ServB if in ServB i call a hashtable.get service from where will I get the hashtable(object) to pass as input in serviceB

    1
    idnkx user

    Vikram

    Hi Hasan, Yes, you can use hastable.get service in different service with hashtable as input..but you should be putting some key pairs in your previous service before you use the get service and pass your hashtable(object/variable) along with keys(object/variable) as inputs to your new service.

Leave a Reply
Guest User

You might also like

Not sure what course is right for you?

Choose the right course for you.
Get the help of our experts and find a course that best suits your needs.


Let`s Connect