-/* Copyright (c) 2009-2010, 2012-2014. The SimGrid Team.
- * All rights reserved. */
+/* Context switching within the JVM. */
+
+/* Copyright (c) 2009-2017. The SimGrid Team. All rights reserved. */
/* This program is free software; you can redistribute it and/or modify it
* under the terms of the license (GNU LGPL) which comes with this package. */
/* This program is free software; you can redistribute it and/or modify it
* under the terms of the license (GNU LGPL) which comes with this package. */
xbt_os_sem_t begin = nullptr;
// Semaphore used to schedule/unschedule the process:
xbt_os_sem_t end = nullptr;
xbt_os_sem_t begin = nullptr;
// Semaphore used to schedule/unschedule the process:
xbt_os_sem_t end = nullptr;
friend class JavaContextFactory;
JavaContext(std::function<void()> code,
void_pfn_smxprocess_t cleanup_func,
friend class JavaContextFactory;
JavaContext(std::function<void()> code,
void_pfn_smxprocess_t cleanup_func,
public:
JavaContextFactory();
~JavaContextFactory() override;
JavaContext* self() override;
JavaContext* create_context(std::function<void()> code,
public:
JavaContextFactory();
~JavaContextFactory() override;
JavaContext* self() override;
JavaContext* create_context(std::function<void()> code,