original_docstring: Check if this property can be stored.
  
    Args:
      request_trusted: If the request is trusted.
      request_app_id: The application ID of the app making the request.
      prop: entity_pb.Property
      indexed: Whether the property is indexed.
  
    Raises:
      apiproxy_errors.ApplicationError: if the property is invalid
    
docstring: Check if this property can be stored.
docstring_tokens: Check if this property can be stored .
code: def CheckProperty(request_trusted, request_app_id, prop, indexed=True):
    """Check if this property can be stored.
  
    Args:
      request_trusted: If the request is trusted.
      request_app_id: The application ID of the app making the request.
      prop: entity_pb.Property
      indexed: Whether the property is indexed.
  
    Raises:
      apiproxy_errors.ApplicationError: if the property is invalid
    """
    name = prop.name()
    value = prop.value()
    meaning = prop.meaning()
    Check(request_trusted or
          not datastore_types.RESERVED_PROPERTY_NAME.match(name),
          'cannot store entity with reserved property name \'%s\'' % name)
    Check(prop.meaning() != entity_pb.Property.INDEX_VALUE,
          'Entities with incomplete properties cannot be written.')
    is_blob = meaning in _BLOB_MEANINGS
    if indexed:
      Check(not is_blob,
            'BLOB, ENITY_PROTO or TEXT property ' + name +
            ' must be in a raw_property field')
      max_length = datastore_types._MAX_STRING_LENGTH
    else:
      if is_blob:
        Check(value.has_stringvalue(),
              'BLOB / ENTITY_PROTO / TEXT raw property ' + name +
              'must have a string value')
      max_length = datastore_types._MAX_RAW_PROPERTY_BYTES
    if meaning == entity_pb.Property.ATOM_LINK:
      max_length = datastore_types._MAX_LINK_PROPERTY_LENGTH
  
    CheckPropertyValue(name, value, max_length)
code_tokens: def CheckProperty ( request_trusted , request_app_id , prop , indexed = True ) : name = prop . name ( ) value = prop . value ( ) meaning = prop . meaning ( ) Check ( request_trusted or not datastore_types . RESERVED_PROPERTY_NAME . match ( name ) , 'cannot store entity with reserved property name \'%s\'' % name ) Check ( prop . meaning ( ) != entity_pb . Property . INDEX_VALUE , 'Entities with incomplete properties cannot be written.' ) is_blob = meaning in _BLOB_MEANINGS if indexed : Check ( not is_blob , 'BLOB, ENITY_PROTO or TEXT property ' + name + ' must be in a raw_property field' ) max_length = datastore_types . _MAX_STRING_LENGTH else : if is_blob : Check ( value . has_stringvalue ( ) , 'BLOB / ENTITY_PROTO / TEXT raw property ' + name + 'must have a string value' ) max_length = datastore_types . _MAX_RAW_PROPERTY_BYTES if meaning == entity_pb . Property . ATOM_LINK : max_length = datastore_types . _MAX_LINK_PROPERTY_LENGTH CheckPropertyValue ( name , value , max_length )
short_docstring: Check if this property can be stored.
short_docstring_tokens: Check if this property can be stored .
comment: """Check if this property can be stored.
  
    Args:
      request_trusted: If the request is trusted.
      request_app_id: The application ID of the app making the request.
      prop: entity_pb.Property
      indexed: Whether the property is indexed.
  
    Raises:
      apiproxy_errors.ApplicationError: if the property is invalid
    """