mirror of
https://github.com/friendica/friendica
synced 2025-05-02 08:24:22 +02:00
Add docs
This commit is contained in:
parent
a83dfc11a0
commit
3897c74deb
21 changed files with 439 additions and 122 deletions
|
@ -7,21 +7,126 @@ namespace Friendica\Protocol\Activity;
|
|||
*/
|
||||
final class ANamespace
|
||||
{
|
||||
/**
|
||||
* Zot is a WebMTA which provides a decentralised identity and communications protocol using HTTPS/JSON.
|
||||
*
|
||||
* @var string
|
||||
* @see https://zotlabs.org/page/zotlabs/specs+zot6+home
|
||||
*/
|
||||
const ZOT = 'http://purl.org/zot';
|
||||
/**
|
||||
* Friendica is using ActivityStreams in version 1.0 for its activities and object types.
|
||||
* Additional types are used for non standard activities.
|
||||
*
|
||||
* @var string
|
||||
* @see https://github.com/friendica/friendica/wiki/ActivityStreams
|
||||
*/
|
||||
const DFRN = 'http://purl.org/macgirvin/dfrn/1.0';
|
||||
/**
|
||||
* This namespace defines an extension for expressing threaded
|
||||
* discussions within the Atom Syndication Format [RFC4287]
|
||||
*
|
||||
* @see https://tools.ietf.org/rfc/rfc4685.txt
|
||||
* @var string
|
||||
*/
|
||||
const THREAD = 'http://purl.org/syndication/thread/1.0';
|
||||
/**
|
||||
* This namespace adds mechanisms to the Atom Syndication Format
|
||||
* that publishers of Atom Feed and Entry documents can use to
|
||||
* explicitly identify Atom entries that have been removed.
|
||||
*
|
||||
* @see https://tools.ietf.org/html/rfc6721
|
||||
* @var string
|
||||
*/
|
||||
const TOMB = 'http://purl.org/atompub/tombstones/1.0';
|
||||
/**
|
||||
* This specification details a model for representing potential and completed activities
|
||||
* using the JSON format.
|
||||
*
|
||||
* @see https://www.w3.org/ns/activitystreams
|
||||
* @var string
|
||||
*/
|
||||
const ACTIVITY2 = 'https://www.w3.org/ns/activitystreams#';
|
||||
/**
|
||||
* Atom Activities 1.0
|
||||
*
|
||||
* This namespace presents an XML format that allows activities on social objects
|
||||
* to be expressed within the Atom Syndication Format.
|
||||
*
|
||||
* @see http://activitystrea.ms/spec/1.0
|
||||
* @var string
|
||||
*/
|
||||
const ACTIVITY = 'http://activitystrea.ms/spec/1.0/';
|
||||
/**
|
||||
* This namespace presents a base set of Object types and Verbs for use with Activity Streams.
|
||||
*
|
||||
* @see http://activitystrea.ms/head/activity-schema.html
|
||||
* @var string
|
||||
*/
|
||||
const ACTIVITY_SCHEMA = 'http://activitystrea.ms/schema/1.0/';
|
||||
/**
|
||||
* Atom Media Extensions
|
||||
*
|
||||
* @var string
|
||||
*/
|
||||
const MEDIA = 'http://purl.org/syndication/atommedia';
|
||||
/**
|
||||
* The Salmon Protocol is an open, simple, standards-based solution that lets
|
||||
* aggregators and sources unify the conversations.
|
||||
*
|
||||
* @see http://www.salmon-protocol.org/salmon-protocol-summary
|
||||
* @var string
|
||||
*/
|
||||
const SALMON_ME = 'http://salmon-protocol.org/ns/magic-env';
|
||||
/**
|
||||
* OStatus is a minimal specification for distributed status updates or microblogging.
|
||||
*
|
||||
* @see https://ostatus.github.io/spec/OStatus%201.0%20Draft%202.html
|
||||
* @var string
|
||||
*/
|
||||
const OSTATUSSUB = 'http://ostatus.org/schema/1.0/subscribe';
|
||||
/**
|
||||
* GeoRSS was designed as a lightweight, community driven way to extend existing feeds with geographic information.
|
||||
*
|
||||
* @see http://www.georss.org/
|
||||
* @var string
|
||||
*/
|
||||
const GEORSS = 'http://www.georss.org/georss';
|
||||
/**
|
||||
* The Portable Contacts specification is designed to make it easier for developers
|
||||
* to give their users a secure way to access the address books and friends lists
|
||||
* they have built up all over the web.
|
||||
*
|
||||
* @see http://portablecontacts.net/draft-spec/
|
||||
* @var string
|
||||
*/
|
||||
const POCO = 'http://portablecontacts.net/spec/1.0';
|
||||
/**
|
||||
* @var string
|
||||
*/
|
||||
const FEED = 'http://schemas.google.com/g/2010#updates-from';
|
||||
/**
|
||||
* OStatus is a minimal specification for distributed status updates or microblogging.
|
||||
*
|
||||
* @see https://ostatus.github.io/spec/OStatus%201.0%20Draft%202.html
|
||||
* @var string
|
||||
*/
|
||||
const OSTATUS = 'http://ostatus.org/schema/1.0';
|
||||
/**
|
||||
* @var string
|
||||
*/
|
||||
const STATUSNET = 'http://status.net/schema/api/1/';
|
||||
/**
|
||||
* This namespace describes the Atom Activity Streams in RDF Vocabulary (AAIR),
|
||||
* defined as a dictionary of named properties and classes using W3C's RDF technology,
|
||||
* and specifically a mapping of the Atom Activity Streams work to RDF.
|
||||
*
|
||||
* @see http://xmlns.notu.be/aair/#RFC4287
|
||||
* @var string
|
||||
*/
|
||||
const ATOM1 = 'http://www.w3.org/2005/Atom';
|
||||
/**
|
||||
* @var string
|
||||
*/
|
||||
const MASTODON = 'http://mastodon.social/schema/1.0';
|
||||
}
|
||||
|
|
103
src/Protocol/Activity/ObjectType.php
Normal file
103
src/Protocol/Activity/ObjectType.php
Normal file
|
@ -0,0 +1,103 @@
|
|||
<?php
|
||||
|
||||
namespace Friendica\Protocol\Activity;
|
||||
|
||||
/**
|
||||
* This class contains the different object types in activities
|
||||
*/
|
||||
final class ObjectType
|
||||
{
|
||||
/**
|
||||
* The "bookmark" object type represents a pointer to some URL -- typically a web page.
|
||||
*
|
||||
* @see http://activitystrea.ms/head/activity-schema.html#bookmark
|
||||
* @var string
|
||||
*/
|
||||
const BOOKMARK = ANamespace::ACTIVITY_SCHEMA . 'bookmark';
|
||||
/**
|
||||
* The "comment" object type represents a textual response to another object.
|
||||
*
|
||||
* @see http://activitystrea.ms/head/activity-schema.html#comment
|
||||
* @var string
|
||||
*/
|
||||
const COMMENT = ANamespace::ACTIVITY_SCHEMA . 'comment';
|
||||
/**
|
||||
* The "comment" object type represents a textual response to another object.
|
||||
* (Default type for items)
|
||||
*
|
||||
* @see http://activitystrea.ms/head/activity-schema.html#note
|
||||
* @var string
|
||||
*/
|
||||
const NOTE = ANamespace::ACTIVITY_SCHEMA . 'note';
|
||||
/**
|
||||
* The "person" object type represents a user account.
|
||||
*
|
||||
* @see http://activitystrea.ms/head/activity-schema.html#person
|
||||
* @var string
|
||||
*/
|
||||
const PERSON = ANamespace::ACTIVITY_SCHEMA . 'person';
|
||||
/**
|
||||
* The "image" object type represents a graphical image.
|
||||
*
|
||||
* @see http://activitystrea.ms/head/activity-schema.html#image
|
||||
* @var string
|
||||
*/
|
||||
const IMAGE = ANamespace::ACTIVITY_SCHEMA . 'image';
|
||||
/**
|
||||
* @var string
|
||||
*/
|
||||
const PHOTO = ANamespace::ACTIVITY_SCHEMA . 'photo';
|
||||
/**
|
||||
* The "video" object type represents video content,
|
||||
* which usually consists of a motion picture track and an audio track.
|
||||
*
|
||||
* @see http://activitystrea.ms/head/activity-schema.html#video
|
||||
* @var string
|
||||
*/
|
||||
const VIDEO = ANamespace::ACTIVITY_SCHEMA . 'video';
|
||||
/**
|
||||
* @var string
|
||||
*/
|
||||
const PROFILE_PHOTO = ANamespace::ACTIVITY_SCHEMA . 'profile-photo';
|
||||
/**
|
||||
* @var string
|
||||
*/
|
||||
const ALBUM = ANamespace::ACTIVITY_SCHEMA . 'photo-album';
|
||||
/**
|
||||
* The "event" object type represents an event that occurs in a certain place during a particular interval of time.
|
||||
*
|
||||
* @see http://activitystrea.ms/head/activity-schema.html#event
|
||||
* @var string
|
||||
*/
|
||||
const EVENT = ANamespace::ACTIVITY_SCHEMA . 'event';
|
||||
/**
|
||||
* The "group" object type represents a grouping of objects in which member objects can join or leave.
|
||||
*
|
||||
* @see http://activitystrea.ms/head/activity-schema.html#group
|
||||
* @var string
|
||||
*/
|
||||
const GROUP = ANamespace::ACTIVITY_SCHEMA . 'group';
|
||||
|
||||
|
||||
/**
|
||||
* @var string
|
||||
*/
|
||||
const HEART = ANamespace::DFRN . '/heart';
|
||||
/**
|
||||
* @var string
|
||||
*/
|
||||
const TAGTERM = ANamespace::DFRN . '/tagterm';
|
||||
/**
|
||||
* @var string
|
||||
*/
|
||||
const PROFILE = ANamespace::DFRN . '/profile';
|
||||
|
||||
|
||||
/**
|
||||
* The "question" object type represents a question or poll.
|
||||
*
|
||||
* @see http://activitystrea.ms/head/activity-schema.html#question
|
||||
* @var string
|
||||
*/
|
||||
const QUESTION = 'http://activityschema.org/object/question';
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue