# # @file\r
-# \r
+#\r
# This file is used to handle the variable attributes and property information\r
#\r
#\r
-# Copyright (c) 2015, Intel Corporation. All rights reserved.<BR>\r
+# Copyright (c) 2015 - 2018, Intel Corporation. All rights reserved.<BR>\r
# This program and the accompanying materials\r
# are licensed and made available under the terms and conditions of the BSD License\r
# which accompanies this distribution. The full text of the license may be found at\r
# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,\r
# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.\r
#\r
- \r
+\r
class VariableAttributes(object):\r
EFI_VARIABLE_NON_VOLATILE = 0x00000001\r
EFI_VARIABLE_BOOTSERVICE_ACCESS = 0x00000002\r
"RT":EFI_VARIABLE_RUNTIME_ACCESS,\r
"RO":VAR_CHECK_VARIABLE_PROPERTY_READ_ONLY\r
}\r
- \r
+\r
def __init__(self):\r
pass\r
- \r
+\r
@staticmethod\r
def GetVarAttributes(var_attr_str):\r
VarAttr = 0x00000000\r
VarProp = 0x00000000\r
- \r
+\r
attr_list = var_attr_str.split(",")\r
for attr in attr_list:\r
attr = attr.strip()\r
if attr == 'RO':\r
VarProp = VariableAttributes.VAR_CHECK_VARIABLE_PROPERTY_READ_ONLY\r
else:\r
- VarAttr = VarAttr | VariableAttributes.VarAttributesMap.get(attr, 0x00000000) \r
+ VarAttr = VarAttr | VariableAttributes.VarAttributesMap.get(attr, 0x00000000)\r
return VarAttr, VarProp\r
@staticmethod\r
def ValidateVarAttributes(var_attr_str):\r