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

Unified Diff: include/fletch_api.h

Issue 1659163007: Rename fletch -> dartino (Closed) Base URL: https://github.com/dartino/sdk.git@master
Patch Set: address comments Created 4 years, 11 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 | « include/dartino_relocation_api.h ('k') | include/fletch_relocation_api.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: include/fletch_api.h
diff --git a/include/fletch_api.h b/include/fletch_api.h
deleted file mode 100644
index 66a223f465ee8bdab9d65c8ede78a0e4dbccc06f..0000000000000000000000000000000000000000
--- a/include/fletch_api.h
+++ /dev/null
@@ -1,106 +0,0 @@
-// Copyright (c) 2015, the Dartino project authors. Please see the AUTHORS file
-// for details. All rights reserved. Use of this source code is governed by a
-// BSD-style license that can be found in the LICENSE.md file.
-
-#ifndef INCLUDE_FLETCH_API_H_
-#define INCLUDE_FLETCH_API_H_
-
-#include <stdbool.h>
-
-#ifdef _MSC_VER
-// TODO(herhut): Do we need a __declspec here for Windows?
-#define FLETCH_VISIBILITY_DEFAULT
-#else
-#define FLETCH_VISIBILITY_DEFAULT __attribute__((visibility("default")))
-#endif
-
-#ifdef __cplusplus
-#define FLETCH_EXPORT extern "C" FLETCH_VISIBILITY_DEFAULT
-#else
-#define FLETCH_EXPORT FLETCH_VISIBILITY_DEFAULT
-#endif
-
-typedef void* FletchProgram;
-typedef void* FletchPrintInterceptor;
-typedef void (*PrintInterceptionFunction)(
- const char* message, int out, void* data);
-typedef void (*ProgramExitCallback)(FletchProgram*, int exitcode, void* data);
-
-// Setup must be called before using any of the other API methods.
-FLETCH_EXPORT void FletchSetup(void);
-
-// TearDown should be called when an application is done using the
-// fletch API in order to free up resources.
-FLETCH_EXPORT void FletchTearDown(void);
-
-// Wait for a debugger connection. The debugger will build the program
-// to run in the VM and start it.
-FLETCH_EXPORT void FletchWaitForDebuggerConnection(int port);
-
-// Load a program from a snapshot.
-FLETCH_EXPORT FletchProgram FletchLoadSnapshot(unsigned char* snapshot,
- int length);
-
-// Load the snapshot from the file and load the program from the snapshot.
-FLETCH_EXPORT FletchProgram FletchLoadSnapshotFromFile(const char* path);
-
-// Delete a program.
-FLETCH_EXPORT void FletchDeleteProgram(FletchProgram program);
-
-// Load a program from the given location. Location should point to a
-// reloacted program heap with appended info block, usually build using
-// the flashtool utility or by relocating a loaded program.
-FLETCH_EXPORT FletchProgram FletchLoadProgramFromFlash(void* location,
- size_t size);
-
-// Starts the main method of the program. The given callback will be called once
-// all processes of the program have terminated.
-//
-// The [callback] might be called on FletchVM internal threads and is not
-// allowed to use the Fletch API.
-// TODO(kustermann/herhut): We should
-// * make clear what the callback can do and what not (e.g.
-// FletchDeleteProgram)
-// * use thread-local storage - at least in debug mode - which ensures this.
-FLETCH_EXPORT void FletchStartMain(FletchProgram program,
- ProgramExitCallback callback,
- void* callback_data);
-
-// Run the main method of the program and wait until it is done executing.
-FLETCH_EXPORT int FletchRunMain(FletchProgram program);
-
-// Run the main method of multiple programs and wait until all of them are done
-// executing.
-FLETCH_EXPORT void FletchRunMultipleMain(int count,
- FletchProgram* programs,
- int* exitcodes);
-
-// Load the snapshot from the file, load the program from the
-// snapshot, run the main process of that program and wait until it is done
-// executing.
-FLETCH_EXPORT void FletchRunSnapshotFromFile(const char* path);
-
-// Add a default shared library for the dart:ffi foreign lookups.
-// More than one default shared library can be added. The libraries
-// are used for foreign lookups where no library has been specified.
-// The libraries are searched in the order in which they are added.
-// The library string must be null-terminated and Fletch does not
-// take over ownership of the passed in string.
-FLETCH_EXPORT bool FletchAddDefaultSharedLibrary(const char* library);
-
-// Register a print interception function. When a print occurs the passed
-// function will be called with the message, an output id 2 for stdout or output
-// id 3 for stderr, as well as the data associated with this registration.
-// The result of registration is an interceptor instance that can be used to
-// subsequently unregister the interceptor.
-FLETCH_EXPORT FletchPrintInterceptor FletchRegisterPrintInterceptor(
- PrintInterceptionFunction function,
- void* data);
-
-// Unregister a print interceptor. This must be called with an interceptor
-// instance that was created using the registration function. The interceptor
-// instance is reclaimed and no longer valid after having called this function.
-FLETCH_EXPORT void FletchUnregisterPrintInterceptor(
- FletchPrintInterceptor interceptor);
-
-#endif // INCLUDE_FLETCH_API_H_
« no previous file with comments | « include/dartino_relocation_api.h ('k') | include/fletch_relocation_api.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698