mirror of
https://github.com/nextcloud/documentation.git
synced 2025-12-12 07:29:47 +07:00
Fix warnings in developer_manual
Signed-off-by: Joas Schilling <coding@schilljs.com>
This commit is contained in:
@@ -18,7 +18,7 @@ You can add 3rd party php packages with `Composer`_. Composer will download the
|
||||
Dependency hell
|
||||
^^^^^^^^^^^^^^^
|
||||
|
||||
Be careful with which packages you add to an app. PHP can not load two version of the same class twice, hence there can be conflicts between Nextcloud Server and an app or between two or more apps if they require the same package. So try to keep the number of production dependencies to a minimum and see :ref:`composer-bin-tools`.
|
||||
Be careful with which packages you add to an app. PHP can not load two version of the same class twice, hence there can be conflicts between Nextcloud Server and an app or between two or more apps if they require the same package. So try to keep the number of production dependencies to a minimum and see :ref:`app-composer-bin-tools`.
|
||||
|
||||
Conflict example
|
||||
****************
|
||||
|
||||
@@ -24,7 +24,7 @@ Back-end changes
|
||||
----------------
|
||||
|
||||
Changed APIs
|
||||
************
|
||||
^^^^^^^^^^^^
|
||||
|
||||
* ``AppFramework\Http\Request::getHeader`` always returns a string (and not null).
|
||||
* ``Security\ICrypto::decrypt`` only accepts strings.
|
||||
|
||||
@@ -59,7 +59,7 @@ Nextcloud 26 supports PHP8.0 and later. This allows the migration from PHPDoc an
|
||||
Planned removal of PSR-0 class loading
|
||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
|
||||
Nextcloud is still loading classes that follow the long deprecated and replaced :ref:`PSR-0 standard <psr0>`. Nextcloud 26 is the last version that register a generic PSR-0 class loader. From Nextcloud 27 on apps have to either change class file names to match PSR-4 or ship their own (composer) class loader for PSR-0 files or. (`PR#36434 <https://github.com/nextcloud/server/pull/36114>`_ by `ChristophWurst <https://github.com/ChristophWurst>`_)
|
||||
Nextcloud is still loading classes that follow the long deprecated and replaced :ref:`PSR-0 standard <psr0>`. Nextcloud 26 is the last version that register a generic PSR-0 class loader. From Nextcloud 27 on apps have to either change class file names to match PSR-4 or ship their own (composer) class loader for PSR-0 files or. (`PR#36114 <https://github.com/nextcloud/server/pull/36114>`_ by `ChristophWurst <https://github.com/ChristophWurst>`_)
|
||||
|
||||
Dependency Injection Parameters
|
||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
|
||||
@@ -90,9 +90,8 @@ If a modification time should be set, you can by adding it as header with date a
|
||||
|
||||
curl -X MOVE -u roeland:pass
|
||||
--header 'Destination: https://server/remote.php/dav/files/roeland/dest/file.zip' \
|
||||
--header 'X-OC-Mtime: 1547545326' \
|
||||
--header 'Destination: https://server/remote.php/dav/files/roeland/dest/file.zip' \
|
||||
--header 'X-OC-Mtime: 1547545326' \
|
||||
--header 'X-OC-Mtime: 1547545326'
|
||||
|
||||
Otherwise the current upload date will be used as modification date.
|
||||
|
||||
The chunks and the upload folder will be deleted afterwards.
|
||||
@@ -126,7 +125,9 @@ are uploaded to.
|
||||
Start by creating a folder with a unique name. You can list the current available
|
||||
folder but if you take a random UUID chances of collision are tiny.
|
||||
|
||||
``curl -X MKCOL -u roeland:pass https://server/remote.php/dav/uploads/roeland/myapp-e1663913-4423-4efe-a9cd-26e7beeca3c0``
|
||||
.. code-block::
|
||||
|
||||
curl -X MKCOL -u roeland:pass https://server/remote.php/dav/uploads/roeland/myapp-e1663913-4423-4efe-a9cd-26e7beeca3c0
|
||||
|
||||
Uploading chunks
|
||||
^^^^^^^^^^^^^^^^
|
||||
@@ -144,8 +145,10 @@ sorting always works.
|
||||
Where ``XXXXXXXXXXXXXXX`` is the start byte of the chunk (with leading zeros) and
|
||||
``YYYYYYYYYYYYYYY`` is the end byte of the chunk with leading zeros.
|
||||
|
||||
``curl -X PUT -u roeland:pass https://server/remote.php/dav/uploads/roeland/myapp-e1663913-4423-4efe-a9cd-26e7beeca3c0/000000000000000-000000010485759 --data-binary @chunk1``
|
||||
``curl -X PUT -u roeland:pass https://server/remote.php/dav/uploads/roeland/myapp-e1663913-4423-4efe-a9cd-26e7beeca3c0/000000010485760-000000015728640 --data-binary @chunk2``
|
||||
.. code-block::
|
||||
|
||||
curl -X PUT -u roeland:pass https://server/remote.php/dav/uploads/roeland/myapp-e1663913-4423-4efe-a9cd-26e7beeca3c0/000000000000000-000000010485759 --data-binary @chunk1
|
||||
curl -X PUT -u roeland:pass https://server/remote.php/dav/uploads/roeland/myapp-e1663913-4423-4efe-a9cd-26e7beeca3c0/000000010485760-000000015728640 --data-binary @chunk2
|
||||
|
||||
This will upload 2 chunks of a file. The first chunk is 10MB in size and the second
|
||||
chunk is 5MB in size.
|
||||
@@ -155,12 +158,18 @@ Assembling the chunks
|
||||
|
||||
Assembling the chunk on the server is a matter of initiating a move from the client.
|
||||
|
||||
``curl -X MOVE -u roeland:pass --header 'Destination:https://server/remote.php/dav/files/roeland/dest/file.zip' https://server/remote.php/dav/uploads/roeland/myapp-e1663913-4423-4efe-a9cd-26e7beeca3c0/.file``
|
||||
.. code-block::
|
||||
|
||||
curl -X MOVE -u roeland:pass --header 'Destination:https://server/remote.php/dav/files/roeland/dest/file.zip' https://server/remote.php/dav/uploads/roeland/myapp-e1663913-4423-4efe-a9cd-26e7beeca3c0/.file
|
||||
|
||||
The server will now assemble the chunks and move the final file to the folder ``dest/file.zip``.
|
||||
|
||||
If a modification time should be set, you can by adding it as header with date as unixtime:
|
||||
``curl -X MOVE -u roeland:pass --header 'X-OC-Mtime:1547545326' --header 'Destination:https://server/remote.php/dav/files/roeland/dest/file.zip' https://server/remote.php/dav/uploads/roeland/myapp-e1663913-4423-4efe-a9cd-26e7beeca3c0/.file``"
|
||||
|
||||
.. code-block::
|
||||
|
||||
curl -X MOVE -u roeland:pass --header 'X-OC-Mtime:1547545326' --header 'Destination:https://server/remote.php/dav/files/roeland/dest/file.zip' https://server/remote.php/dav/uploads/roeland/myapp-e1663913-4423-4efe-a9cd-26e7beeca3c0/.file
|
||||
|
||||
Otherwise the current upload date will be used as modification date.
|
||||
|
||||
The chunks and the upload folder will be deleted afterwards.
|
||||
@@ -170,4 +179,6 @@ Aborting the upload
|
||||
|
||||
If the upload has to be aborted this is a simple matter or deleting the upload folder.
|
||||
|
||||
``curl -X DELETE -u roeland:pass https://server/remote.php/dav/uploads/roeland/myapp-e1663913-4423-4efe-a9cd-26e7beeca3c0/``
|
||||
.. code-block::
|
||||
|
||||
curl -X DELETE -u roeland:pass https://server/remote.php/dav/uploads/roeland/myapp-e1663913-4423-4efe-a9cd-26e7beeca3c0/
|
||||
|
||||
@@ -262,7 +262,7 @@ When referring to a user inline in your app, a user bubble element can be used.
|
||||
.. _Counter bubbles:
|
||||
|
||||
Counter bubbles
|
||||
------------
|
||||
---------------
|
||||
|
||||
`Counter bubble Vue component <https://nextcloud-vue-components.netlify.app/#/Components/NcCounterBubble>`_.
|
||||
`Penpot counter bubbles <https://design.penpot.app/#/view/db3839da-807b-8052-8002-576401e9a375?page-id=3f784c86-6c27-80c6-8002-6ab157b6bd27§ion=interactions&index=7&share-id=11fde340-21f4-802e-8002-8d8d305e7ab5>`_
|
||||
|
||||
Reference in New Issue
Block a user