代码搜索结果
找到约 10,000 项符合
State Machine 的代码
machine.c
/*
* Copyright (c) 2005, Johns Hopkins University and The EROS Group, LLC.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permit
machine.h
#ifndef MACHINE_H
#define MACHINE_H
/*
* Copyright (c) 2005, Johns Hopkins University and The EROS Group, LLC.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or
machine.java
/* 用内部类来实现接口,
* 当一个类继承一个父类,同时又实现一个接口,
*并且要实现的接口有一个方法与父类的方法同名时,
*可以用内部类来实现这个接口。从而解决这个问题。
*
*/
interface Machine
{
void run();
}
class Person
{
void run()
{
System.out.p
machine.h
/* @(#) machine.h 2.1 87/12/25 12:22:43 */
/*
The contents of this file are hereby released to the public domain.
-- Rahul Dhesi 1986/11/14
*/
/*
This file hold
machine.c
#ifndef LINT
/* @(#) machine.c 2.3 88/01/02 01:21:44 */
static char sccsid[]="@(#) machine.c 2.3 88/01/02 01:21:44";
#endif /* LINT */
/*
The contents of this file are hereby released to the pu
machine.java
interface Machine
{
void run();
}
class Person
{
void run()
{
System.out.println("run");
}
}
class Robot extends Person
{
private class MachineHeart implements Machine
{
p