-
Notifications
You must be signed in to change notification settings - Fork 113
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Signed-off-by: jkoberg <jkoberg@owncloud.com>
- Loading branch information
Showing
2 changed files
with
70 additions
and
14 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,36 +1,70 @@ | ||
// Copyright 2018-2022 CERN | ||
// | ||
// Licensed under the Apache License, Version 2.0 (the "License"); | ||
// you may not use this file except in compliance with the License. | ||
// You may obtain a copy of the License at | ||
// | ||
// http://www.apache.org/licenses/LICENSE-2.0 | ||
// | ||
// Unless required by applicable law or agreed to in writing, software | ||
// distributed under the License is distributed on an "AS IS" BASIS, | ||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
// See the License for the specific language governing permissions and | ||
// limitations under the License. | ||
// | ||
// In applying this license, CERN does not waive the privileges and immunities | ||
// granted to it by virtue of its status as an Intergovernmental Organization | ||
// or submit itself to any jurisdiction. | ||
|
||
package events | ||
|
||
import ( | ||
user "github.com/cs3org/go-cs3apis/cs3/identity/user/v1beta1" | ||
provider "github.com/cs3org/go-cs3apis/cs3/storage/provider/v1beta1" | ||
) | ||
|
||
// FileUploaded is emitted when a file is uploaded | ||
type FileUploaded struct { | ||
FileID string | ||
FileID *provider.Reference | ||
Owner *user.UserId | ||
} | ||
|
||
//FileDownloaded is emitted when a file is downloaded | ||
type FileDownloaded struct { | ||
FileID string | ||
FileID *provider.Reference | ||
Owner *user.UserId | ||
} | ||
|
||
// ItemTrashed is emitted when a file or folder is trashed | ||
type ItemTrashed struct { | ||
FileID string | ||
FileID *provider.Reference | ||
Owner *user.UserId | ||
} | ||
|
||
// ItemMoved is emitted when a file or folder is moved | ||
type ItemMoved struct { | ||
FileID string | ||
FileID *provider.Reference | ||
Owner *user.UserId | ||
OldReference *provider.Reference | ||
} | ||
|
||
// ItemPurged is emitted when a file or folder is removed from trashbin | ||
type ItemPurged struct { | ||
FileID string | ||
FileID *provider.Reference | ||
Owner *user.UserId | ||
} | ||
|
||
// ItemRestored is emitted when a file or folder is restored from trashbin | ||
type ItemRestored struct { | ||
FileID string | ||
FileID *provider.Reference | ||
Owner *user.UserId | ||
OldReference *provider.Reference | ||
Key string | ||
} | ||
|
||
// FileVersionRestored is emitted when a file version is restored | ||
type FileVersionRestored struct { | ||
FileID string | ||
FileID *provider.Reference | ||
Owner *user.UserId | ||
Key string | ||
} |