---
title: "Discussion on \"Enums and Annotations\" | Hashnode"
description: "Discussion on \"Enums and Annotations\". Two special-purpose families of reference types: Enums and Annotations.\nItem 34: Use enums instead of int constants\nint constants\npublic static final int APPLE_FUJI = 0;\nDisadvantages:\n\nNo type safety (other values can be used, even if not present in..."
url: "https://hashnode.com/posts/enums-and-annotations/6001a998dd5fce29feec83d0"
---

[Feed](https://hashnode.com/feed) /

Discussion

# [Enums and Annotations](https://techtenets.hashnode.dev/enums-and-annotations?utm_source=hashnode&utm_medium=feed)

Two special-purpose families of reference types: Enums and Annotations. Item 34: Use enums instead of int constants int constants public static final int APPLE\_FUJI = 0; Disadvantages: No type safety (other values can be used, even if not present in...

Jan 15, 2021 · 4 min read · techtenets.hashnode.dev  
Updated Dec 28, 2021  
Read the article

-   [#java](https://hashnode.com/tag/java)
-   [#programming-blogs](https://hashnode.com/tag/programming-blogs)
-   [#software-engineering](https://hashnode.com/tag/software-engineering)

## Written by

[Shubham](https://hashnode.com/@sam007)

@sam007 · India

  
[View profile](https://hashnode.com/@sam007)

Curious by nature and Software Engineer by profession

## Responses

Markdown supported · ⌘↵ to post

No responses yet.
