Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(744)

Unified Diff: mojo/public/go/bindings/invalid_handle.go

Issue 2250183003: Make the fuchsia mojo/public repo the source of truth. (Closed) Base URL: https://github.com/domokit/mojo.git@master
Patch Set: Created 4 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « mojo/public/go/bindings/interface.go ('k') | mojo/public/go/bindings/message.go » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: mojo/public/go/bindings/invalid_handle.go
diff --git a/mojo/public/go/bindings/invalid_handle.go b/mojo/public/go/bindings/invalid_handle.go
deleted file mode 100644
index 3b1edb523eca342a2009c1dfa43e449880b9e4d5..0000000000000000000000000000000000000000
--- a/mojo/public/go/bindings/invalid_handle.go
+++ /dev/null
@@ -1,101 +0,0 @@
-// Copyright 2015 The Chromium Authors. All rights reserved.
-// Use of this source code is governed by a BSD-style license that can be
-// found in the LICENSE file.
-
-package bindings
-
-import (
- "mojo/public/go/system"
-)
-
-// InvalidHandle is a handle that will always be invalid.
-type InvalidHandle struct {
-}
-
-func (h *InvalidHandle) Close() system.MojoResult {
- return system.MOJO_RESULT_INVALID_ARGUMENT
-}
-
-func (h *InvalidHandle) IsValid() bool {
- return false
-}
-
-func (h *InvalidHandle) NativeHandle() system.MojoHandle {
- return system.MOJO_HANDLE_INVALID
-}
-
-func (h *InvalidHandle) ReleaseNativeHandle() system.MojoHandle {
- return system.MOJO_HANDLE_INVALID
-}
-
-func (h *InvalidHandle) ToUntypedHandle() system.UntypedHandle {
- return h
-}
-
-func (h *InvalidHandle) Wait(signals system.MojoHandleSignals, deadline system.MojoDeadline) (system.MojoResult, system.MojoHandleSignalsState) {
- return system.MOJO_RESULT_INVALID_ARGUMENT, system.MojoHandleSignalsState{}
-}
-
-func (h *InvalidHandle) ToConsumerHandle() system.ConsumerHandle {
- return h
-}
-
-func (h *InvalidHandle) ToProducerHandle() system.ProducerHandle {
- return h
-}
-
-func (h *InvalidHandle) ToMessagePipeHandle() system.MessagePipeHandle {
- return h
-}
-
-func (h *InvalidHandle) ToSharedBufferHandle() system.SharedBufferHandle {
- return h
-}
-
-func (h *InvalidHandle) ReadData(flags system.MojoReadDataFlags) (system.MojoResult, []byte) {
- return system.MOJO_RESULT_INVALID_ARGUMENT, nil
-}
-
-func (h *InvalidHandle) BeginReadData(flags system.MojoReadDataFlags) (system.MojoResult, []byte) {
- return system.MOJO_RESULT_INVALID_ARGUMENT, nil
-}
-
-func (h *InvalidHandle) EndReadData(numBytesRead int) system.MojoResult {
- return system.MOJO_RESULT_INVALID_ARGUMENT
-}
-
-func (h *InvalidHandle) WriteData(data []byte, flags system.MojoWriteDataFlags) (system.MojoResult, int) {
- return system.MOJO_RESULT_INVALID_ARGUMENT, 0
-}
-
-func (h *InvalidHandle) BeginWriteData(flags system.MojoWriteDataFlags) (system.MojoResult, []byte) {
- return system.MOJO_RESULT_INVALID_ARGUMENT, nil
-}
-
-func (h *InvalidHandle) EndWriteData(numBytesWritten int) system.MojoResult {
- return system.MOJO_RESULT_INVALID_ARGUMENT
-}
-
-func (h *InvalidHandle) ReadMessage(flags system.MojoReadMessageFlags) (system.MojoResult, []byte, []system.UntypedHandle) {
- return system.MOJO_RESULT_INVALID_ARGUMENT, nil, nil
-}
-
-func (h *InvalidHandle) WriteMessage(bytes []byte, handles []system.UntypedHandle, flags system.MojoWriteMessageFlags) system.MojoResult {
- return system.MOJO_RESULT_INVALID_ARGUMENT
-}
-
-func (h *InvalidHandle) DuplicateBufferHandle(opts *system.DuplicateBufferHandleOptions) (system.MojoResult, system.SharedBufferHandle) {
- return system.MOJO_RESULT_INVALID_ARGUMENT, nil
-}
-
-func (h *InvalidHandle) MapBuffer(offset uint64, numBytes int, flags system.MojoMapBufferFlags) (system.MojoResult, []byte) {
- return system.MOJO_RESULT_INVALID_ARGUMENT, nil
-}
-
-func (h *InvalidHandle) UnmapBuffer(buffer []byte) system.MojoResult {
- return system.MOJO_RESULT_INVALID_ARGUMENT
-}
-
-func (h *InvalidHandle) GetBufferInformation() (system.MojoResult, system.MojoBufferInformation) {
- return system.MOJO_RESULT_INVALID_ARGUMENT, system.MojoBufferInformation{}
-}
« no previous file with comments | « mojo/public/go/bindings/interface.go ('k') | mojo/public/go/bindings/message.go » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698