blob: fa591ec56f46e285162a7bfb50f1ae65915889e5 [file] [log] [blame] [edit]
// 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.
module mojo.examples;
enum Department {
SALES,
DEV
};
// TODO(yzshen): [MinVersion=0] is not necessary once we remove the trick in
// the generator which implicitly adds [MinVersion=ordinal+1] to all fields for
// structs without any [MinVersion] annotation.
struct Employee {
[MinVersion=0]
uint64 employee_id;
[MinVersion=0]
string name;
[MinVersion=0]
Department department;
};
interface HumanResourceDatabase {
AddEmployee(Employee employee) => (bool success);
QueryEmployee(uint64 id) => (Employee? employee);
};