当前位置: 首页 > news >正文

建设网站时seo标题百度怎么精准搜关键词

建设网站时seo标题,百度怎么精准搜关键词,初学者求教怎样做网站,网站关键词在哪里添加abstract: 1、用来修饰类,此类被称为抽象类。且此类不能够实例化,包含构造器的,因为子类对象实例化时,需要调用父类的构造器。可以没有抽象方法。 2、此方法称为抽象方法,此方法只有方法的声明&#xff0…

abstract:

1、用来修饰类,此类被称为抽象类。且此类不能够实例化,包含构造器的,因为子类对象实例化时,需要调用父类的构造器。可以没有抽象方法。

2、此方法称为抽象方法,此方法只有方法的声明,没有方法体。

其功能是确定的,通过方法的声明来确定,只是不知道功能如何实现(体现为方法体)

子类必须重写父类所有方法,方可实例化。否则仍是抽象类。

abstract不能修饰私有方法、static方法、final方法、final类

*私有方法不能重写,abstract则必须重写

*静态方法允许调用,而abstract的父类方法不能调用

*final方法不能重写,abstract则必须重写

*final类不能有子类,abstract有子类

例题:

Employee类:

public abstract class Employee {private String name;private int number;private Mydate birthday;public Employee() {}public Employee(String name, int number, Mydate birthday) {this.name = name;this.number = number;this.birthday = birthday;}public String getName() {return name;}public void setName(String name) {this.name = name;}public int getNumber() {return number;}public void setNumber(int number) {this.number = number;}public Mydate getBirthday() {return birthday;}public void setBirthday(Mydate birthday) {this.birthday = birthday;}public abstract double earning();public String toString(){return "姓名,"+name+"数字,"+number+"生日"+birthday.toDateString();}
}

Mydate类:

public class Mydate {private int year;private int month;private int day;public Mydate() {}public Mydate(int year, int month, int day) {this.year = year;this.month = month;this.day = day;}public int getYear() {return year;}public void setYear(int year) {this.year = year;}public int getMonth() {return month;}public void setMonth(int month) {this.month = month;}public int getDay() {return day;}public void setDay(int day) {this.day = day;}public String toDateString(){return year+"年"+month+"月"+day+"日";}
}

SalariedEmployee类:

public class SalariedEmployee extends Employee{private double monthlySalary;public SalariedEmployee() {}public SalariedEmployee(String name, int number, Mydate birthday, double monthlySalary) {super(name, number, birthday);this.monthlySalary = monthlySalary;}public void setMonthlySalary(double monthlySalary) {this.monthlySalary = monthlySalary;}public double earning(){return monthlySalary;}public String toString(){return "SalariedEmployee[" + super.toString()+"]";}}

HourlyEmployee类:

public  class HourlyEmployee extends Employee {private double wage;private int hour;public HourlyEmployee() {}public HourlyEmployee(String name, int number, Mydate birthday, double wage, int hour) {super(name, number, birthday);this.wage = wage;this.hour = hour;}public double getWage() {return wage;}public void setWage(double wage) {this.wage = wage;}public int getHour() {return hour;}public void setHour(int hour) {this.hour = hour;}public  double earning(){return wage*hour;}public String toString(){return "HourlyEmployee[" + super.toString()+"]";}
}

PayrollSystem类:

import java.util.Scanner;public class PayrollSystem {public static void main(String[] args) {Scanner scanner=new Scanner(System.in);Employee[] e=new Employee[2];e[0]=new SalariedEmployee("马国森", 123, new Mydate(2001, 1, 1),5000);e[1]=new HourlyEmployee("王悦",123,new Mydate(2001,2,2),32,5);System.out.println("请输入月份");int input=scanner.nextInt();for (int i = 0; i < e.length; i++) {System.out.println(e[i].toString());System.out.println("工资:"+e[i].earning());if (input == e[i].getBirthday().getMonth()) {System.out.println("生日快乐,加薪200!");}}scanner.close();}}
http://www.hkea.cn/news/506705/

相关文章:

  • 网站的文件结构百度搜索排名怎么收费
  • 全景网站app网络营销工具分析
  • 南京建设工程交易中心网站seo是什么的简称
  • 利用vps做网站关键字排名查询
  • 常熟网站制作找哪家好品牌型网站制作价格
  • 怎么做自己网站推广网络广告
  • 化州网站建设促销方法100种
  • 长沙专业网站设计平台新闻最新消息10条
  • 惠州网站建设制作宣传推广方案
  • 宁波网站推广外包服务长岭网站优化公司
  • 哈尔滨市哪里做淘宝网站seo课程心得体会
  • 做网站建设公司企业一个企业该如何进行网络营销
  • 移动端h5网站开发服务企业seo推广
  • 管理公司网站建设引擎搜索优化
  • 上市公司专利查询网站百度广告投放价格
  • html5电商网页制作网站怎么seo关键词排名优化推广
  • 大同网站建设黄冈网站推广优化找哪家
  • 昌邑网站建设站长之家网站排名
  • 建设企业网站的需求分析免费域名
  • 重庆欧勒精细有限公司网站策划书百度竞价推广开户
  • 怎么做一键添加信任网站ios aso优化工具
  • ps做网站的分辨率多少钱苹果cms永久免费建站程序
  • 网站推广积分常用于网站推广的营销手段是
  • wordpress时间云储存沈阳网站制作优化推广
  • h5响应式网站建设竞价托管哪家效果好
  • 企业解决方案参考网站品牌软文营销案例
  • 做淘客要有好的网站上海百度seo
  • 网站建设 seojsc宁德seo推广
  • 建立网站的作用信息流优化师工作总结
  • 如何建设物流网站近期时事新闻