Class: DiasporaFederation::Entities::SignedRetraction Deprecated

Inherits:
DiasporaFederation::Entity show all
Defined in:
lib/diaspora_federation/entities/signed_retraction.rb

Overview

Deprecated.

will be replaced with Retraction

This entity represents a claim of deletion of a previously federated entity of post type. (StatusMessage)

See Also:

  • Validators::SignedRetractionValidator

Constant Summary

Constants inherited from DiasporaFederation::Entity

DiasporaFederation::Entity::ENTITY_NAME_REGEX, DiasporaFederation::Entity::INVALID_XML_REGEX

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Method Summary collapse

Methods inherited from DiasporaFederation::Entity

class_name, entity_class, entity_name, from_json, from_xml, #to_h, #to_json, #to_s, #to_xml

Methods included from PropertiesDSL

#class_props, #default_values, #entity, #find_property_for_xml_name, #missing_props, #optional_props, #property, #resolv_aliases, #xml_names

Methods included from Logging

included

Constructor Details

#initializeSignedRetraction

Returns a new instance of SignedRetraction



33
34
35
# File 'lib/diaspora_federation/entities/signed_retraction.rb', line 33

def initialize(*)
  raise "Sending SignedRetraction is not supported anymore! Use Retraction instead!"
end

Instance Attribute Details

#authorString (readonly)

The diaspora* ID of the person who deletes a post

Returns:

  • (String)

    diaspora* ID

See Also:



25
# File 'lib/diaspora_federation/entities/signed_retraction.rb', line 25

property :author, :string, xml_name: :sender_handle

#author_signatureString (readonly)

Contains a signature of the entity using the private key of the author of a post This signature is mandatory.

Returns:

  • (String)

    author signature



31
# File 'lib/diaspora_federation/entities/signed_retraction.rb', line 31

property :target_author_signature, :string, default: nil

#target_guidString (readonly)

Guid of a post to be deleted

Returns:

  • (String)

    target guid

See Also:



13
# File 'lib/diaspora_federation/entities/signed_retraction.rb', line 13

property :target_guid, :string

#target_typeString (readonly)

A string describing the type of the target

Returns:

  • (String)

    target type

See Also:



19
# File 'lib/diaspora_federation/entities/signed_retraction.rb', line 19

property :target_type, :string

Class Method Details

.from_hash(hash) ⇒ Retraction

Returns instance

Returns:



38
39
40
# File 'lib/diaspora_federation/entities/signed_retraction.rb', line 38

def self.from_hash(hash)
  Retraction.from_hash(hash)
end