Revision 1428
Added by Jing Tao almost 22 years ago
src/edu/ucsb/nceas/metacat/EmlSAXHandler.java | ||
---|---|---|
384 | 384 |
// we conbine different a permission into one value |
385 | 385 |
int permission = accessRule.getPermission(); |
386 | 386 |
// add permision |
387 |
if ( data.toUpperCase().equals("READ") )
|
|
387 |
if ( data.toUpperCase().equals(READSTRING) )
|
|
388 | 388 |
{ |
389 | 389 |
permission = permission | READ; |
390 | 390 |
} |
391 |
else if ( data.toUpperCase().equals("WRITE") )
|
|
391 |
else if ( data.toUpperCase().equals(WRITESTRING) )
|
|
392 | 392 |
{ |
393 | 393 |
permission = permission | WRITE; |
394 | 394 |
} |
395 |
else if ( data.toUpperCase().equals("CHANGEPERMISSION"))
|
|
395 |
else if ( data.toUpperCase().equals(CHMODSTRING))
|
|
396 | 396 |
{ |
397 | 397 |
permission = permission | CHMOD; |
398 | 398 |
} |
399 |
else if ( data.toUpperCase().equals("ALL") )
|
|
399 |
else if ( data.toUpperCase().equals(ALLSTRING) )
|
|
400 | 400 |
{ |
401 | 401 |
permission = permission | ALL; |
402 | 402 |
} |
Also available in: Unified diff
Change some hard code to constant string.