Listing 13.4 structure question


Hi all,
I’m enjoying the book, lots of programming books are not really my style this one is pretty close.
I was a hardware engineer Assembly, and Verilog programmer but Java to android is a big jump.
I’ve got everything working fine but just confused about the first line and the last line in listing 13.4?

android:id="@+id/helloMoonFragment" whats the purpose / where is this id used? Its not a layout file, or a string?
I thought it was a type O but the program crashes without it.

android:name=“” this line is pointing to the class but what’s with hellomoon?
It’s not declared anywhere or instantiated and it’s all lowercase?
I’m looking for the structure of building a layout fragment specifying a fragment class in a fragment element…right?


I think I got it? id of the fragment…instantiation of the fragments class.