登录
首页 » Java » graphics

graphics

于 2014-05-05 发布 文件大小:2KB
0 311
下载积分: 1 下载次数: 1

代码说明:

  实验一:类与对象实验: 几何图形类的设计 实验目的:掌握用类进行面向对象程序设计的方法,掌握使用对象作为类的成员变量,掌握方法的参数传递,掌握静态域和静态方法。 实验内容:编写4个类:Rectangle、Circle、Geometry、Exa,具体要求如下: ① Rectangle类有double型成员变量表示矩形左上角的位置坐标及矩形的宽和高,要求提供修改和返回各成员变量的方法。 ② Circle类有double型成员变量表示圆心坐标和圆的半径,要求提供修改和返回各成员变量的方法。 ③ Geometry类有Rectangle类和Circle型的成员变量rect和circle。即Geometry类创建的对象由一个矩形和一个圆组合而成。要求该类提供修改rect、circle位置和大小的方法;提供显示rect和circle位置关系的方法,并能够显示圆是否完全坐落于矩形中。 ④ 要求能对创建的Rectangle类和Circle类对象数目进行统计。 Exa类含有main方法,在main方法中用Geometry类创建对象,该对象调用相应的方法 设置圆和矩形的位置及大小并输出圆是否包含在矩形中。输出当前Rectangle和Circle 对象数目。 (test one)

下载说明:请别用迅雷下载,失败请重下,重下不扣分!

发表评论

0 个回复

  • 05917017
    说明:  实时通讯和P2P开发工具,由一套易用的控件和DLL组成,功能包括好友列表(Real-time communication and P2P development tools, consisting of a set of easy-to-use controls and DLL, including a list of friends)
    2019-04-07 07:47:53下载
    积分:1
  • 连接ch432
    说明:  基于STM32HAL库的外接串口CH432,针对单片机串口不够用的情况用(The external serial port CH432 based on STM32HAL library is used to solve the problem that the serial port of single chip computer is not enough.)
    2021-04-20 09:08:50下载
    积分:1
  • 一个微型NIDS实现例子
    一个微型NIDS实现例子- A miniature NIDS realization example
    2022-02-01 16:03:22下载
    积分:1
  • c++API
    说明:  计算机软件开发参考手册,参考手册,方便实用(Reference Manual, Convenient and Practical)
    2019-02-10 00:27:18下载
    积分:1
  • virtual-Spectrum-Analyzer
    di电子测量技术基础的课程设计总结报告,题目是基于虚拟仪器技术的频谱分析仪设计,本文详细论述了开发平台labview8.5实现该设计各部分功能的原理及方法,并对本设计创新点,存在问题等做了分析,附带个人总结。(di Electronic Measurement Technology curriculum design summary report entitled spectrum analyzer based virtual instrument technology, the paper discusses in detail the principles and methods of development platform labview8.5 implement the function of each part of the design, and this design innovation, there is a problems were analyzed, with personal summary.)
    2016-10-25 12:04:22下载
    积分:1
  • 3793832861910016
    ewaearewrerewrwerqeqrewrqere
    2020-06-23 01:20:02下载
    积分:1
  • shx3
    Handle unalignment exceptions in kernel space.
    2015-03-05 10:06:52下载
    积分:1
  • moni-shubiao
    这是一个模拟鼠标点击屏幕的资料,很适合感兴趣的初学者参考学习。(This is the information of some simulated mouse click on the screen, and interested friends are worth considering learning.)
    2015-12-15 15:00:56下载
    积分:1
  • Homework07
    说明:  创建一个类,提供与java .lang.Math同名的所有方法,但每个方法均按度数而非弧度进行运算。具体要求是:在自己编写的类中,对Math类中的每一个方法加一层包装。(Create a class that provides all methods with the same name as java. lang. Math, but each method operates in degrees rather than radians. Specific requirements are: in their own class, each method in the Math class with a layer of packaging.)
    2020-12-07 21:59:20下载
    积分:1
  • MFC List Control controls
    MFC List Control 控件实现添加单元格编辑和单元格下拉列表项(MFC List Control controls add cell edit and cell drop-down list items.)
    2018-06-27 10:44:04下载
    积分:1
  • 696516资源总数
  • 106914会员总数
  • 0今日下载