Regarding anonymous hash in PERL


 
Thread Tools Search this Thread
Top Forums Shell Programming and Scripting Regarding anonymous hash in PERL
# 1  
Old 12-20-2010
Regarding anonymous hash in PERL

Hi,

I have doubt regarding the Anonymous hash. For creating a object we are generally using Anonymous hash.
My Doubt is:
Why we are only using Anonymous hash?? Instead of Anonymous hash can we use global hash variable and take its reference for creating an object using same bless function?? What is the main reason behind using Anonymous hash only.

Any help on this regard is Welcome!!

Thanks in Advance.
Login or Register to Ask a Question

Previous Thread | Next Thread

10 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

Perl hash of hashes anonymous array

Hello experts. I'm having problems with a snippet of code. I was hoping to get help/advice to correct. A file that this script parses has changed to the point where I can no longer use a scalar, it looks as though I need to create an array for a hash of hashes below. The first output of... (1 Reply)
Discussion started by: timj123
1 Replies

2. Programming

Perl: restrict perl from automaticaly creating a hash branches on check

My issue is that the perl script (as I have done it so far) created empty branches when I try to check some branches on existence. I am using multydimentional hashes: found it as the best way for information that I need to handle. Saing multidimentional I means hash of hashes ... So, I have ... (2 Replies)
Discussion started by: alex_5161
2 Replies

3. Shell Programming and Scripting

Compare values of hashes of hash for n number of hash in perl without sorting.

Hi, I have an hashes of hash, where hash is dynamic, it can be n number of hash. i need to compare data_count values of all . my %result ( $abc => { 'data_count' => '10', 'ID' => 'ABC122', } $def => { 'data_count' => '20', 'ID' => 'defASe', ... (1 Reply)
Discussion started by: asak
1 Replies

4. Shell Programming and Scripting

perl hash - using a range as a hash key.

Hi, In Perl, is it possible to use a range of numbers with '..' as a key in a hash? Something in like: %hash = ( '768..1536' => '1G', '1537..2560' => '2G' ); That is, the range operation is evaluated, and all members of the range are... (3 Replies)
Discussion started by: dsw
3 Replies

5. Shell Programming and Scripting

Perl Hash:Can not keep hash data in the same order that it was inserted

Can Someone explain me why even using Tie::IxHash I can not get the output data in the same order that it was inserted? See code below. #!/usr/bin/perl use warnings; use Tie::IxHash; use strict; tie (my %programs, "Tie::IxHash"); while (my $line = <DATA>) { chomp $line; my(... (1 Reply)
Discussion started by: jgfcoimbra
1 Replies

6. Shell Programming and Scripting

Need explanation on Anonymous hash in PERL!!

Hi, I have doubt regarding the Anonymous hash. For creating a object we are generally using Anonymous hash. My Doubt is: Why we are only using Anonymous hash?? Instead of Anonymous hash can we use global hash variable and take its reference for creating an object using same bless function??... (0 Replies)
Discussion started by: jatanig
0 Replies

7. Shell Programming and Scripting

perl hash

This is my data 1 0 1 0 1 1 1 2 1 6 1 7 Assume that first field is key and 2nd field is value I want to create a hash in perl, on this data. My hash should having uniq key and all values by , separated. 1,0,0,1,2,6,7 1 will be my key and rest of are should be values. (3 Replies)
Discussion started by: pritish.sas
3 Replies

8. Shell Programming and Scripting

perl using hash

i want to ask is it i can use hash in perl to store a page number with a list of words which is in that page and then print it out? Example Page 1 contains a are boy cat ............. (a list of sorted words) how can i store it in a hash? Thank you (3 Replies)
Discussion started by: mingming88
3 Replies

9. Shell Programming and Scripting

perl help on hash

I have line which is read from xml doc. I want to put this line into hash(perl variable). find line below and how i want to put this in hash <font size="10" type="int" name="ABC" > hash key should be size, type and name with corresponding value I doing as below:- $line =~ s/\s*.*?\s//;... (3 Replies)
Discussion started by: aju_kup
3 Replies

10. Shell Programming and Scripting

Hash in perl

Hi Help me with some good links of Hash with in Hash .(Multidimensional hash).. Regards Harikrishna (1 Reply)
Discussion started by: Harikrishna
1 Replies
Login or Register to Ask a Question
Tspi_Hash_SetHashValue(3)				     Library Functions Manual					 Tspi_Hash_SetHashValue(3)

						     TCG Software Stack Developer's Reference

NAME
Tspi_Hash_SetHashValue - Sets the hash value of a hash object for non-SHA1 hash objects. SYNOPSIS
#include <tss/platform.h> #include <tss/tcpa_defines.h> #include <tss/tcpa_typedef.h> #include <tss/tcpa_struct.h> #include <tss/tss_typedef.h> #include <tss/tss_structs.h> #include <tss/tspi.h> TSS_RESULT Tspi_Hash_SetHashValue(TSS_HHASH hHash, UINT32 ulHashValueLength, BYTE* rgbHashValue); DESCRIPTION
Tspi_Hash_SetHashValue sets the hash value of a hash object. If the object was created with the flag TSS_HASH_OTHER, then the hash identi- fier has to be set by calling Tspi_SetAttribData to perform the sign operation. PARAMETERS
hHash The handle to the hash object instance whose hash value should be signed. ulHashValueLength Indicates the length of the hash value data provided at the parameter rgbHashValue. rgbHashValue A pointer to the hash value data. RETURN CODES
Tspi_Hash_SetHashValue returns TSS_SUCCESS on success, otherwise one of the following values is returned: TSS_E_INVALID_HANDLE hHash is not a valid handle. TSS_E_INTERNAL_ERROR An internal SW error has been detected. TSS_E_BAD_PARAMETER One or more parameters is bad. TSS_E_HASH_INVALID_LENGTH Hash length is inconsistent with hash algorithm. TSS_E_HASH_NO_DATA Hash object has no internal hash value. CONFORMING TO
Tspi_Hash_SetHashValue conforms to the Trusted Computing Group Software Specification version 1.1 Golden SEE ALSO
Tspi_Hash_UpdateHash(3), Tspi_Hash_Sign(3), Tspi_Hash_GetHashValue(3). TSS 1.1 2004-05-25 Tspi_Hash_SetHashValue(3)