def protonation_indicator(ick): """ protonation indicator (last character of the key) """ assert is_valid(ick) cap_dct = apf.first_named_capture(Parse.PATTERN, ick) prot = cap_dct[Parse.PROT_KEY] return prot
def second_hash(ick): """ the second hash block, indicating stereochemistry etc. """ assert is_valid(ick) cap_dct = apf.first_named_capture(Parse.PATTERN, ick) hash2 = cap_dct[Parse.HASH2_KEY] return hash2
def version_indicator(ick): """ the version indicator following the second hash block """ assert is_valid(ick) cap_dct = apf.first_named_capture(Parse.PATTERN, ick) ver = cap_dct[Parse.VERSION_KEY] return ver
def first_hash(ick): """ the first hash block, indicating connectivity """ assert is_valid(ick) cap_dct = apf.first_named_capture(Parse.PATTERN, ick) hash1 = cap_dct[Parse.HASH1_KEY] return hash1
def protonation_indicator(ick): """ Parse final character of InChIKey for the protonation indicator. :param ick: InChIKey :type ick: str :rtype: str """ assert is_valid(ick) cap_dct = apf.first_named_capture(Parse.PATTERN, ick) prot = cap_dct[Parse.PROT_KEY] return prot
def version_indicator(ick): """ Parse InChIKey second-hash block for the InChIKey version indicator. :param ick: InChIKey :type ick: str :rtype: str """ assert is_valid(ick) cap_dct = apf.first_named_capture(Parse.PATTERN, ick) ver = cap_dct[Parse.VERSION_KEY] return ver
def second_hash(ick): """ Parse InChIKey for the second hash block, indicating stereochemistry. :param ick: InChIKey :type ick: str :rtype: str """ assert is_valid(ick) cap_dct = apf.first_named_capture(Parse.PATTERN, ick) hash2 = cap_dct[Parse.HASH2_KEY] return hash2
def first_hash(ick): """ Parse InChIKey for the first hash block, indicating connectivity. :param ick: InChIKey :type ick: str :rtype: str """ assert is_valid(ick) cap_dct = apf.first_named_capture(Parse.PATTERN, ick) hash1 = cap_dct[Parse.HASH1_KEY] return hash1