Here you can find the source of align(int size)
public static int align(int size)
//package com.java2s; // Use of this source code is governed by a BSD-style license that can be public class Main { /**//from www . j a va 2 s .co m * Alignment in bytes for mojo serialization. */ public static final int ALIGNMENT = 8; /** * Align |size| on {@link BindingsHelper#ALIGNMENT}. */ public static int align(int size) { return (size + ALIGNMENT - 1) & ~(ALIGNMENT - 1); } /** * Align |size| on {@link BindingsHelper#ALIGNMENT}. */ public static long align(long size) { return (size + ALIGNMENT - 1) & ~(ALIGNMENT - 1); } }