Commit 0a8775f1 authored by Klaus Wölfel's avatar Klaus Wölfel

wendelin: add setArrayDtypeNames so that names can be changed from sandbox

parent 1f3db135
...@@ -133,13 +133,20 @@ class DataArray(BigFile): ...@@ -133,13 +133,20 @@ class DataArray(BigFile):
Get numpy array dtype Get numpy array dtype
""" """
return self.getArray().dtype return self.getArray().dtype
security.declareProtected(Permissions.AccessContentsInformation, 'getArrayDtypeNames') security.declareProtected(Permissions.AccessContentsInformation, 'getArrayDtypeNames')
def getArrayDtypeNames(self): def getArrayDtypeNames(self):
""" """
Get numpy array dtype names Get numpy array dtype names
""" """
return self.getArray().dtype.names return self.getArray().dtype.names
security.declareProtected(Permissions.AccessContentsInformation, 'setArrayDtypeNames')
def setArrayDtypeNames(self, names):
"""
Set numpy array dtype names
"""
self.getArray().dtype.names = names
security.declareProtected(Permissions.View, 'index_html') security.declareProtected(Permissions.View, 'index_html')
def index_html(self, REQUEST, RESPONSE, format=_MARKER, inline=_MARKER, **kw): def index_html(self, REQUEST, RESPONSE, format=_MARKER, inline=_MARKER, **kw):
......
...@@ -46,9 +46,9 @@ ...@@ -46,9 +46,9 @@
<key> <string>text_content_warning_message</string> </key> <key> <string>text_content_warning_message</string> </key>
<value> <value>
<tuple> <tuple>
<string>W:145, 42: Redefining built-in \'format\' (redefined-builtin)</string> <string>W:152, 42: Redefining built-in \'format\' (redefined-builtin)</string>
<string>W:162, 4: Redefining built-in \'range\' (redefined-builtin)</string> <string>W:169, 4: Redefining built-in \'range\' (redefined-builtin)</string>
<string>W:189, 10: No exception type(s) specified (bare-except)</string> <string>W:196, 10: No exception type(s) specified (bare-except)</string>
</tuple> </tuple>
</value> </value>
</item> </item>
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment