Drupal 8  8.0.2
FileStorage Class Reference
Inheritance diagram for FileStorage:

Public Member Functions

 spaceUsed ($uid=NULL, $status=FILE_STATUS_PERMANENT)
 
- Public Member Functions inherited from SqlContentEntityStorage
 getFieldStorageDefinitions ()
 
 __construct (EntityTypeInterface $entity_type, Connection $database, EntityManagerInterface $entity_manager, CacheBackendInterface $cache, LanguageManagerInterface $language_manager)
 
 getBaseTable ()
 
 getRevisionTable ()
 
 getDataTable ()
 
 getRevisionDataTable ()
 
 setEntityType (EntityTypeInterface $entity_type)
 
 getTableMapping (array $storage_definitions=NULL)
 
 delete (array $entities)
 
 save (EntityInterface $entity)
 
 requiresEntityStorageSchemaChanges (EntityTypeInterface $entity_type, EntityTypeInterface $original)
 
 requiresFieldStorageSchemaChanges (FieldStorageDefinitionInterface $storage_definition, FieldStorageDefinitionInterface $original)
 
 requiresEntityDataMigration (EntityTypeInterface $entity_type, EntityTypeInterface $original)
 
 requiresFieldDataMigration (FieldStorageDefinitionInterface $storage_definition, FieldStorageDefinitionInterface $original)
 
 onEntityTypeCreate (EntityTypeInterface $entity_type)
 
 onEntityTypeUpdate (EntityTypeInterface $entity_type, EntityTypeInterface $original)
 
 onEntityTypeDelete (EntityTypeInterface $entity_type)
 
 onFieldStorageDefinitionCreate (FieldStorageDefinitionInterface $storage_definition)
 
 onFieldStorageDefinitionUpdate (FieldStorageDefinitionInterface $storage_definition, FieldStorageDefinitionInterface $original)
 
 onFieldStorageDefinitionDelete (FieldStorageDefinitionInterface $storage_definition)
 
 onFieldDefinitionDelete (FieldDefinitionInterface $field_definition)
 
 onBundleCreate ($bundle, $entity_type_id)
 
 onBundleDelete ($bundle, $entity_type_id)
 
 finalizePurge (FieldStorageDefinitionInterface $storage_definition)
 
 countFieldData ($storage_definition, $as_bool=FALSE)
 
- Public Member Functions inherited from ContentEntityStorageBase
 __construct (EntityTypeInterface $entity_type, EntityManagerInterface $entity_manager, CacheBackendInterface $cache)
 
 hasData ()
 
 createTranslation (ContentEntityInterface $entity, $langcode, array $values=[])
 
 onFieldStorageDefinitionCreate (FieldStorageDefinitionInterface $storage_definition)
 
 onFieldStorageDefinitionUpdate (FieldStorageDefinitionInterface $storage_definition, FieldStorageDefinitionInterface $original)
 
 onFieldStorageDefinitionDelete (FieldStorageDefinitionInterface $storage_definition)
 
 onFieldDefinitionCreate (FieldDefinitionInterface $field_definition)
 
 onFieldDefinitionUpdate (FieldDefinitionInterface $field_definition, FieldDefinitionInterface $original)
 
 onFieldDefinitionDelete (FieldDefinitionInterface $field_definition)
 
 purgeFieldData (FieldDefinitionInterface $field_definition, $batch_size)
 
 finalizePurge (FieldStorageDefinitionInterface $storage_definition)
 
 loadRevision ($revision_id)
 
 resetCache (array $ids=NULL)
 
- Public Member Functions inherited from EntityStorageBase
 __construct (EntityTypeInterface $entity_type)
 
 getEntityTypeId ()
 
 getEntityType ()
 
 loadUnchanged ($id)
 
 resetCache (array $ids=NULL)
 
 create (array $values=array())
 
 load ($id)
 
 loadMultiple (array $ids=NULL)
 
 delete (array $entities)
 
 save (EntityInterface $entity)
 
 loadByProperties (array $values=array())
 
 getQuery ($conjunction= 'AND')
 
 getAggregateQuery ($conjunction= 'AND')
 
- Public Member Functions inherited from EntityHandlerBase
 setModuleHandler (ModuleHandlerInterface $module_handler)
 
- Public Member Functions inherited from EntityStorageInterface
 deleteRevision ($revision_id)
 

Additional Inherited Members

- Static Public Member Functions inherited from SqlContentEntityStorage
static createInstance (ContainerInterface $container, EntityTypeInterface $entity_type)
 
- Static Public Member Functions inherited from ContentEntityStorageBase
static createInstance (ContainerInterface $container, EntityTypeInterface $entity_type)
 
- Data Fields inherited from EntityStorageInterface
const FIELD_LOAD_CURRENT = 'FIELD_LOAD_CURRENT'
 
const FIELD_LOAD_REVISION = 'FIELD_LOAD_REVISION'
 
- Protected Member Functions inherited from SqlContentEntityStorage
 initTableLayout ()
 
 getStorageSchema ()
 
 doLoadMultiple (array $ids=NULL)
 
 getFromStorage (array $ids=NULL)
 
 mapFromStorageRecords (array $records, $load_from_revision=FALSE)
 
 loadFromSharedTables (array &$values, array &$translations)
 
 doLoadRevisionFieldItems ($revision_id)
 
 doDeleteRevisionFieldItems (ContentEntityInterface $revision)
 
 buildPropertyQuery (QueryInterface $entity_query, array $values)
 
 buildQuery ($ids, $revision_id=FALSE)
 
 doDeleteFieldItems ($entities)
 
 doSaveFieldItems (ContentEntityInterface $entity, array $names=[])
 
 has ($id, EntityInterface $entity)
 
 saveToSharedTables (ContentEntityInterface $entity, $table_name=NULL, $new_revision=NULL)
 
 mapToStorageRecord (ContentEntityInterface $entity, $table_name=NULL)
 
 isColumnSerial ($table_name, $schema_name)
 
 mapToDataStorageRecord (EntityInterface $entity, $table_name=NULL)
 
 saveRevision (ContentEntityInterface $entity)
 
 getQueryServiceName ()
 
 loadFromDedicatedTables (array &$values, $load_from_revision)
 
 saveToDedicatedTables (ContentEntityInterface $entity, $update=TRUE, $names=array())
 
 deleteFromDedicatedTables (ContentEntityInterface $entity)
 
 deleteRevisionFromDedicatedTables (ContentEntityInterface $entity)
 
 wrapSchemaException (callable $callback)
 
 readFieldItemsToPurge (FieldDefinitionInterface $field_definition, $batch_size)
 
 purgeFieldItems (ContentEntityInterface $entity, FieldDefinitionInterface $field_definition)
 
 storageDefinitionIsDeleted (FieldStorageDefinitionInterface $storage_definition)
 
- Protected Member Functions inherited from ContentEntityStorageBase
 doCreate (array $values)
 
 initFieldValues (ContentEntityInterface $entity, array $values=[], array $field_names=[])
 
 readFieldItemsToPurge (FieldDefinitionInterface $field_definition, $batch_size)
 
 purgeFieldItems (ContentEntityInterface $entity, FieldDefinitionInterface $field_definition)
 
 doLoadRevisionFieldItems ($revision_id)
 
 doSaveFieldItems (ContentEntityInterface $entity, array $names=[])
 
 doDeleteFieldItems ($entities)
 
 doDeleteRevisionFieldItems (ContentEntityInterface $revision)
 
 invokeTranslationHooks (ContentEntityInterface $entity)
 
 invokeStorageLoadHook (array &$entities)
 
 invokeFieldMethod ($method, ContentEntityInterface $entity)
 
 invokeFieldPostSave (ContentEntityInterface $entity, $update)
 
 hasFieldValueChanged (FieldDefinitionInterface $field_definition, ContentEntityInterface $entity, ContentEntityInterface $original)
 
 populateAffectedRevisionTranslations (ContentEntityInterface $entity)
 
 cleanIds (array $ids)
 
 getFromPersistentCache (array &$ids=NULL)
 
 setPersistentCache ($entities)
 
 buildCacheId ($id)
 
- Protected Member Functions inherited from EntityStorageBase
 getFromStaticCache (array $ids)
 
 setStaticCache (array $entities)
 
 invokeHook ($hook, EntityInterface $entity)
 
 doCreate (array $values)
 
 doLoadMultiple (array $ids=NULL)
 
 postLoad (array &$entities)
 
 mapFromStorageRecords (array $records)
 
 has ($id, EntityInterface $entity)
 
 doDelete ($entities)
 
 doPreSave (EntityInterface $entity)
 
 doSave ($id, EntityInterface $entity)
 
 doPostSave (EntityInterface $entity, $update)
 
 buildPropertyQuery (QueryInterface $entity_query, array $values)
 
 getQueryServiceName ()
 
- Protected Member Functions inherited from EntityHandlerBase
 moduleHandler ()
 
- Protected Attributes inherited from SqlContentEntityStorage
 $tableMapping
 
 $revisionKey = FALSE
 
 $langcodeKey = FALSE
 
 $defaultLangcodeKey = FALSE
 
 $baseTable
 
 $revisionTable
 
 $dataTable
 
 $revisionDataTable
 
 $database
 
 $storageSchema
 
 $languageManager
 
- Protected Attributes inherited from ContentEntityStorageBase
 $bundleKey = FALSE
 
 $entityManager
 
 $cacheBackend
 
- Protected Attributes inherited from EntityStorageBase
 $entities = array()
 
 $entityTypeId
 
 $entityType
 
 $idKey
 
 $uuidKey
 
 $langcodeKey
 
 $uuidService
 
 $entityClass
 
- Protected Attributes inherited from EntityHandlerBase
 $moduleHandler
 

Detailed Description

File storage for files.

Member Function Documentation

spaceUsed (   $uid = NULL,
  $status = FILE_STATUS_PERMANENT 
)

{Determines total disk space used by a single user or the whole filesystem.

Parameters
int$uidOptional. A user id, specifying NULL returns the total space used by all non-temporary files.
int$status(Optional) The file status to consider. The default is to only consider files in status FILE_STATUS_PERMANENT.
Returns
int An integer containing the number of bytes used.
}

Implements FileStorageInterface.

References Drupal\database().

Here is the call graph for this function:


The documentation for this class was generated from the following file: