code: def fromXML(self, name, attrs, content, ttFont):
      # Create a lookup for all the simple names that make sense to
      # bitmap size table. Only read the information from these names.
      dataNames = set(self._getXMLMetricNames())
      for element in content:
          if not isinstance(element, tuple):
              continue
          name, attrs, content = element
          if name == "sbitLineMetrics":
              direction = attrs["direction"]
              assert direction in (
                  "hori",
                  "vert",
              ), "SbitLineMetrics direction specified invalid."
              metricObj = SbitLineMetrics()
              metricObj.fromXML(name, attrs, content, ttFont)
              vars(self)[direction] = metricObj
          elif name in dataNames:
              vars(self)[name] = safeEval(attrs["value"])
          else:
              log.warning(
                  "unknown name '%s' being ignored in BitmapSizeTable.",
                  name,
              )
  
imports: from fontTools.misc import sstruct
  from .None import DefaultTable
  from fontTools.misc.textTools import bytesjoin, safeEval
  from .BitmapGlyphMetrics import BigGlyphMetrics, bigGlyphMetricsFormat, SmallGlyphMetrics, smallGlyphMetricsFormat
  import struct
  import itertools
  from collections import deque
  import logging
label_desc: Use image node_id 3 for calling the BitmapSizeTable obj's underlying member method code with example usage: obj.fromXML(name, attrs, content, ttFont) without return types