使用集合让一切井井有条
根据您的偏好保存内容并对其进行分类。
google.appengine.api.mail_errors 的源代码
#!/usr/bin/env python
#
# Copyright 2007 Google Inc.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
#
"""Exceptions raised by the Mail API."""
[docs]class Error(Exception):
"""Base Mail error type."""
[docs]class BadRequestError(Error):
"""The email is not valid."""
[docs]class InvalidSenderError(Error):
"""The sender is not permitted to send mail for this application."""
[docs]class InvalidEmailError(Error):
"""The specified email is invalid."""
[docs]class InvalidAttachmentTypeError(Error):
"""The file type of the attachment is invalid."""
[docs]class MissingRecipientsError(Error):
"""A recipient was not specified in the message."""
[docs]class MissingSenderError(Error):
"""A sender was not specified in the message."""
[docs]class MissingSubjectError(Error):
"""The subject was not specified in the message."""
[docs]class MissingBodyError(Error):
"""A body was not specified in the message."""
[docs]class PayloadEncodingError(Error):
"""The payload encoding is unknown."""
[docs]class UnknownEncodingError(PayloadEncodingError):
"""The encoding is unknown."""
[docs]class UnknownCharsetError(PayloadEncodingError):
"""The character set is unknown."""
如未另行说明,那么本页面中的内容已根据知识共享署名 4.0 许可获得了许可,并且代码示例已根据 Apache 2.0 许可获得了许可。有关详情,请参阅 Google 开发者网站政策。Java 是 Oracle 和/或其关联公司的注册商标。
最后更新时间 (UTC):2022-10-21。
[{
"type": "thumb-down",
"id": "hardToUnderstand",
"label":"Hard to understand"
},{
"type": "thumb-down",
"id": "incorrectInformationOrSampleCode",
"label":"Incorrect information or sample code"
},{
"type": "thumb-down",
"id": "missingTheInformationSamplesINeed",
"label":"Missing the information/samples I need"
},{
"type": "thumb-down",
"id": "translationIssue",
"label":"翻译问题"
},{
"type": "thumb-down",
"id": "otherDown",
"label":"其他"
}]
[{
"type": "thumb-up",
"id": "easyToUnderstand",
"label":"易于理解"
},{
"type": "thumb-up",
"id": "solvedMyProblem",
"label":"解决了我的问题"
},{
"type": "thumb-up",
"id": "otherUp",
"label":"其他"
}]
{"lastModified": "\u6700\u540e\u66f4\u65b0\u65f6\u95f4 (UTC)\uff1a2022-10-21\u3002"}