JavaScript Learning Notes

1. JavaScript Objects

  1. Objects are variables too, but objects can contain many values.

    1
    var car = {type:"flat", model:"500",color:"white"}

    1.1 The value are written as name:value pairs
    1.2 JavaScript objects are container for named value.

  2. Two ways to access objects:

    2.1.

    1
    objectName.propertyName

    2.2.

    1
    objectName["propertyName"]

Read More

Share Comments

Java review note


Read More

Share Comments

Difference between static method and instance method

静态方法和实例方法的区别主要体现在两个方面:

在外部调用静态方法时,可以使用”类名.方法名”的方式,也可以使用”对象名.方法名”的方式。而实例方法只有后面这种方式。也就是说,调用静态方法可以无需创建对象。

静态方法在访问本类的成员时,只允许访问静态成员(即静态成员变量和静态方法),而不允许访问实例成员变量和实例方法;实例方法则无此限制。

Read More

Share Comments

Hello World

Welcome to Hexo! This is your very first post. Check documentation for more info. If you get any problems when using Hexo, you can find the answer in troubleshooting or you can ask me on GitHub.

Quick Start

Create a new post

1
$ hexo new "My New Post"

More info: Writing

Run server

1
$ hexo server

More info: Server

Generate static files

1
$ hexo generate

More info: Generating

Deploy to remote sites

1
$ hexo deploy

More info: Deployment

Share Comments